-
Type: Task
-
Resolution: Done
-
Affects Version/s: None
-
Component/s: None
In rails console, with identity_map_enabled: false
> Book.find(123).series.books.count
14
> Book.find(123).series.books.to_a.length
14
> Book.find(123).series.books.to_a.length
14
With identity_map_enabled: true
> Book.find(123).series.books.count
14
> Book.find(123).series.books.to_a.length
14
> Book.find(123).series.books.to_a.length
16
My books are reproducing! It looks like one of the books is getting shoved into the second result set multiple times. I'm happy to investigate further if you tell me where to look.
class Book include Mongoid::Document belongs_to :series end class Series include Mongoid::Document has_many :books end