We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents d349490 + b3125c8 commit 1e89e43Copy full SHA for 1e89e43
railties/CHANGELOG.md
@@ -1,5 +1,7 @@
1
## Rails 4.0.0 (unreleased) ##
2
3
+* Ensure that RAILS_ENV is set when accessing Rails.env *Steve Klabnik*
4
+
5
* Don't eager-load app/assets and app/views *Elia Schito*
6
7
* Add `.rake` to list of file extensions included by `rake notes` and `rake notes:custom`. *Brent J. Nordquist*
railties/lib/rails.rb
@@ -85,7 +85,10 @@ def root
85
end
86
87
def env
88
- @_env ||= ActiveSupport::StringInquirer.new(ENV["RAILS_ENV"] || ENV["RACK_ENV"] || "development")
+ @_env ||= begin
89
+ ENV["RAILS_ENV"] ||= ENV["RACK_ENV"] || "development"
90
+ ActiveSupport::StringInquirer.new(ENV["RAILS_ENV"])
91
+ end
92
93
94
def env=(environment)
0 commit comments