Module: TinyDyno::Changeable
- Extended by:
- ActiveSupport::Concern
- Included in:
- DocumentComposition
- Defined in:
- lib/tiny_dyno/changeable.rb
Overview
Defines behaviour for dirty tracking.
Instance Method Summary collapse
-
#changes ⇒ Hash<String, Array<Object, Object> ] The changes.
Get all the changes for the document.
Instance Method Details
#changes ⇒ Hash<String, Array<Object, Object> ] The changes.
Get all the changes for the document.
42 43 44 45 46 47 48 49 50 |
# File 'lib/tiny_dyno/changeable.rb', line 42 def changes _changes = {} changed.each do |attr| next if attr.nil? change = attribute_change(attr) _changes[attr] = change end _changes end |