-
Type:
Task
-
Resolution: Done
-
Affects Version/s: None
-
Component/s: None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
find_and_modify isn't updating an object in the identity map. It's fairly easy to see, just do something like this:
band = Band.create(name: "Tool") Band.where(_id: band.id).find_and_modify(:$push => {notes: {text: 'Hello'}}) band.reload() band.notes.length # => 1 Band.find(band.id).notes.length # => 0
Changing the find_and_modify to an update works as expected.