Permalink
Browse files

Fix some more Ruby 1.9 compatibility issues (loading path related)

  • Loading branch information...
1 parent 9444db6 commit 27c48be739c0690cedd6f33eecdaf659ed258d57 @FooBarWidget FooBarWidget committed Nov 17, 2009
Showing with 3 additions and 7 deletions.
  1. +3 −7 lib/phusion_passenger/railz/application_spawner.rb
View
10 lib/phusion_passenger/railz/application_spawner.rb
@@ -169,12 +169,8 @@ def spawn_application!
if @lower_privilege
lower_privilege('config/environment.rb', @lowest_user)
end
-
- # require Rails' environment, using the same path as the original rails dispatcher,
- # which normally does: require File.dirname(__FILE__) + "/../config/environment"
- # thus avoiding the possibility of including the same file twice.
- require 'public/../config/environment'
-
+
+ require File.expand_path('config/environment')
require 'dispatcher'
end
if success
@@ -298,7 +294,7 @@ def load_environment_with_passenger
end
end
if File.exist?('config/preinitializer.rb')
- require 'config/preinitializer'
+ require File.expand_path('config/preinitializer')
end
require File.expand_path('config/environment')
if ActionController::Base.page_cache_directory.blank?

0 comments on commit 27c48be

Please sign in to comment.