diff options
Diffstat (limited to 'railties/lib')
-rw-r--r-- | railties/lib/rails/application.rb | 2 | ||||
-rw-r--r-- | railties/lib/rails/application/bootstrap.rb | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/railties/lib/rails/application.rb b/railties/lib/rails/application.rb index 90118c8cfc..e14719c758 100644 --- a/railties/lib/rails/application.rb +++ b/railties/lib/rails/application.rb @@ -11,7 +11,6 @@ module Rails autoload :Railties, 'rails/application/railties' autoload :RoutesReloader, 'rails/application/routes_reloader' - # TODO Ensure production settings are read properly class << self private :new alias :configure :class_eval @@ -24,7 +23,6 @@ module Rails raise "You cannot have more than one Rails::Application" if Rails.application super Rails.application = base.instance - base.require_environment! end protected diff --git a/railties/lib/rails/application/bootstrap.rb b/railties/lib/rails/application/bootstrap.rb index 819d00be4e..3c339ffc57 100644 --- a/railties/lib/rails/application/bootstrap.rb +++ b/railties/lib/rails/application/bootstrap.rb @@ -3,6 +3,10 @@ module Rails module Bootstrap include Initializable + initializer :load_environment_config do |app| + app.require_environment! + end + initializer :load_all_active_support do |app| require "active_support/all" unless app.config.active_support.bare end |