Closed ArturAguiar closed 10 years ago
I've checked in a different resolution. Read my comment in #25. You can close both of these issues if other uses of the users relationship check out (course_enrollments works perfectly with the fix).
I agree. That solution looks a lot better. Thank you!
As discussed in the meeting, the error in issue #25 was avoided, but not fixed. I am not too familiar with the "include" tag in a has_many relationship. But based on what I've read it's about resource eager loading and/or efficiency.
I tried changing the original has_many association to use a scope block, but that didn't help. I tried removing each of the includes and order individually, but different errors would pop up.
The only way I found to resolve the issue was to remove the include tag altogether.
Was:
Became (with scope block):
Now is:
Would this change cause any problems?