Open Erol opened 9 years ago
Something like this?
user = User.new value: 1 user.attributes.changed? #=> nil user.value = 2 user.attributes.changed? #=> {value: 2} user.attributes.changed?(:value) #=> true
Helpers can also be mixed-in to the entity object itself:
user = User.new value: 1 user.changed? #=> nil user.value = 2 user.changed? #=> {value: 2} user.changed?(:value) #=> true
Something like this?