instance method reset_changes

Ruby on Rails 4.1.16

Since v4.1.16 Last seen in v4.2.9 Private

Available in: v4.1.16 v4.2.9

Signature

reset_changes()

Removes all dirty data: current changes and previous changes

Source
# File activemodel/lib/active_model/dirty.rb, line 174
      def reset_changes
        @previously_changed = ActiveSupport::HashWithIndifferentAccess.new
        @changed_attributes = ActiveSupport::HashWithIndifferentAccess.new
      end

Defined in activemodel/lib/active_model/dirty.rb line 174 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActiveModel::Dirty

Type at least 2 characters to search.

↑↓ navigate · open · esc close