Module: CollectiveIdea::ActionController::Audited
- Defined in:
- lib/acts_as_audited/audit_sweeper.rb
Overview
:nodoc:
Instance Method Summary collapse
Instance Method Details
#audit(*models) ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/acts_as_audited/audit_sweeper.rb', line 4 def audit(*models) ActiveSupport::Deprecation.warn("#audit is deprecated. Declare #acts_as_audited in your models.", caller) = models. # Parse the options hash looking for classes .each_key do |key| models << [key, .delete(key)] if key.is_a?(Class) end models.each do |(model, )| model.send :acts_as_audited, || {} end end |