Class: ActiveRecord::Base
- Inherits:
-
Object
- Object
- ActiveRecord::Base
- Defined in:
- lib/super_diff/active_record/monkey_patches.rb
Overview
rubocop:disable Style/BracesAroundHashParameters, Style/ClassAndModuleChildren
Instance Method Summary collapse
Instance Method Details
#attributes_for_super_diff ⇒ Object
3 4 5 6 7 |
# File 'lib/super_diff/active_record/monkey_patches.rb', line 3 def attributes_for_super_diff (attributes.keys.sort - ["id"]).reduce({ id: id }) do |hash, key| hash.merge(key.to_sym => attributes[key]) end end |