Closed infiton closed 9 years ago
when a couchbase model has a mutable attribute you cannot modify that attribute in place without changing it for all other instances of that class:
class Foo < Couchbase::Model attribute :foo, default: [] end f = Foo.new f.foo # => [] f.foo << "Hi" f.foo #=> ["Hi"] g = Foo.new g.foo # => ["Hi"] g.foo << "Bye" f.foo # => ["Hi", "Bye"]
apologies, this is a duplicate issue: #6
when a couchbase model has a mutable attribute you cannot modify that attribute in place without changing it for all other instances of that class: