aboutsummaryrefslogtreecommitdiffstats
path: root/config/boot.rb
diff options
context:
space:
mode:
authorRobin Houston <robin.houston@gmail.com>2012-06-03 14:28:43 +0100
committerRobin Houston <robin.houston@gmail.com>2012-06-03 14:28:43 +0100
commit0806fcc7d477b45d158e8a152b1f927f395d3aa7 (patch)
tree3fc0d5028a42c3a9f7971a349d67d90ab071a223 /config/boot.rb
parent775e122cb4824c9734f50db0dd2967779636080e (diff)
File.dirname(__FILE__) is not necessarily absolute
It’s weird that there’s so much code here that implicitly assumes File.dirname(__FILE__) is an absolute path, because really in general it very much is not! This assumption was invalidated by the recent bundler-awareness changes.
Diffstat (limited to 'config/boot.rb')
-rw-r--r--config/boot.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/config/boot.rb b/config/boot.rb
index 943029408..906a2bace 100644
--- a/config/boot.rb
+++ b/config/boot.rb
@@ -6,7 +6,7 @@
# better. Look for a config/rails_env file, and read stuff from there if
# it exists. Put just a line like this in there:
# ENV['RAILS_ENV'] = 'production'
-rails_env_file = File.join(File.dirname(__FILE__), 'rails_env.rb')
+rails_env_file = File.expand_path(File.join(File.dirname(__FILE__), 'rails_env.rb'))
if File.exists?(rails_env_file)
require rails_env_file
end