aboutsummaryrefslogtreecommitdiffstats
path: root/activemodel/lib/active_model/state_machine.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activemodel/lib/active_model/state_machine.rb')
-rw-r--r--activemodel/lib/active_model/state_machine.rb8
1 files changed, 2 insertions, 6 deletions
diff --git a/activemodel/lib/active_model/state_machine.rb b/activemodel/lib/active_model/state_machine.rb
index 96df6539ae..89afc4abb6 100644
--- a/activemodel/lib/active_model/state_machine.rb
+++ b/activemodel/lib/active_model/state_machine.rb
@@ -1,14 +1,10 @@
-Dir[File.dirname(__FILE__) + "/state_machine/*.rb"].sort.each do |path|
- filename = File.basename(path)
- require "active_model/state_machine/#{filename}"
-end
-
module ActiveModel
module StateMachine
class InvalidTransition < Exception
end
def self.included(base)
+ require 'active_model/state_machine/machine'
base.extend ClassMethods
end
@@ -63,4 +59,4 @@ module ActiveModel
end
end
end
-end \ No newline at end of file
+end