Closed javierg closed 1 year ago
Object identity for hash is lost when we switch from Hash to HashWithIndifferentAccess for role property values.
Hash
HashWithIndifferentAccess
Current behaivor:
class Model < Dolly::Document property :foo, class_name: Hash end h = {} doc = Model.new(foo: h) doc.foo.object_id == doc.send(:doc)[:foo].object_id # => false
Expects:
doc.foo.object_id == doc.send(:doc)[:foo].object_id # => true
Object identity for hash is lost when we switch from
Hash
toHashWithIndifferentAccess
for role property values.Current behaivor:
Expects: