-
Type: Task
-
Resolution: Done
-
Affects Version/s: None
-
Component/s: None
-
None
I have a Blog model like:
class Blog
has_many :posts
default_scope includes(:posts)
end
so that posts are eagerly loaded when a Blog query is made.
I experience unexpected behaviour if I query for the same blog > 1 times. It seems like the post data are reapplied to the array, so that the array contains duplicates of the posts.
Is this expected behaviour?
Please let me know if you need more info.