Permalink
Browse files

Fix #5847 and #4045. Force load AR::Base before loading an applicatio…

…n model.
  • Loading branch information...
1 parent 65fa512 commit 1e2b7a8335b5511444ea9ce76cccad2a50bc75a6 @kennyj committed Apr 17, 2012
Showing with 5 additions and 0 deletions.
  1. +5 −0 activerecord/lib/active_record/railtie.rb
@@ -121,5 +121,10 @@ class Railtie < Rails::Railtie
end
end
end
+
+ config.after_initialize do
+ # We should load ActiveRecord::Base class before loading an application model.
+ require "active_record/base"
+ end
end
end

0 comments on commit 1e2b7a8

Please sign in to comment.