Skip to content

Commit

Permalink
Merge pull request #326 from sineed/sineed-ensure-initial-state-symbol
Browse files Browse the repository at this point in the history
Use a symbol as the name of AR callback instead of block
  • Loading branch information
alto committed Mar 18, 2016
2 parents 5247b50 + 389d56e commit d4a8b59
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions lib/aasm/persistence/active_record_persistence.rb
Expand Up @@ -32,9 +32,7 @@ def self.included(base)
base.send(:include, AASM::Persistence::Base)
base.send(:include, AASM::Persistence::ActiveRecordPersistence::InstanceMethods)

base.after_initialize do
aasm_ensure_initial_state
end
base.after_initialize :aasm_ensure_initial_state

# ensure state is in the list of states
base.validate :aasm_validate_states
Expand Down

0 comments on commit d4a8b59

Please sign in to comment.