aboutsummaryrefslogtreecommitdiffstats
path: root/railties/environments
diff options
context:
space:
mode:
Diffstat (limited to 'railties/environments')
-rw-r--r--railties/environments/boot.rb12
1 files changed, 7 insertions, 5 deletions
diff --git a/railties/environments/boot.rb b/railties/environments/boot.rb
index 7f30e829a9..1df433a7eb 100644
--- a/railties/environments/boot.rb
+++ b/railties/environments/boot.rb
@@ -1,8 +1,10 @@
-RAILS_ROOT = File.join(File.dirname(__FILE__), '..')
+RAILS_ROOT = File.join(File.dirname(__FILE__), '..') unless defined?(RAILS_ROOT)
-unless File.directory?("#{RAILS_ROOT}/vendor/rails")
+if File.directory?("#{RAILS_ROOT}/vendor/rails")
+ require "#{RAILS_ROOT}/vendor/rails/railties/lib/initializer"
+else
require 'rubygems'
require 'initializer'
-else
- require "#{RAILS_ROOT}/vendor/rails/railties/lib/initializer"
-end \ No newline at end of file
+end
+
+Rails::Initializer.run(:set_load_path) \ No newline at end of file