diff options
author | Jeremy Kemper <jeremykemper@gmail.com> | 2015-03-20 08:14:11 -0700 |
---|---|---|
committer | Jeremy Kemper <jeremykemper@gmail.com> | 2015-03-20 08:14:11 -0700 |
commit | 5154089c181e9b36753b193bd7ffb141e88232f1 (patch) | |
tree | e72783fd1351026a4bd8847127abba222f44d118 /activerecord/lib | |
parent | a4e7a6f9d63b93fff4ba78a32a930d1f5f97da29 (diff) | |
download | rails-5154089c181e9b36753b193bd7ffb141e88232f1.tar.gz rails-5154089c181e9b36753b193bd7ffb141e88232f1.tar.bz2 rails-5154089c181e9b36753b193bd7ffb141e88232f1.zip |
Revert "Merge pull request #19404 from dmathieu/remove_rack_env"
Preserving RACK_ENV behavior.
This reverts commit 7bdc7635b885e473f6a577264fd8efad1c02174f, reversing
changes made to 45786be516e13d55a1fca9a4abaddd5781209103.
Diffstat (limited to 'activerecord/lib')
-rw-r--r-- | activerecord/lib/active_record/connection_handling.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/connection_handling.rb b/activerecord/lib/active_record/connection_handling.rb index d0deb7751c..24f5849e45 100644 --- a/activerecord/lib/active_record/connection_handling.rb +++ b/activerecord/lib/active_record/connection_handling.rb @@ -1,6 +1,6 @@ module ActiveRecord module ConnectionHandling - RAILS_ENV = -> { (Rails.env if defined?(Rails.env)) || ENV["RAILS_ENV"] } + RAILS_ENV = -> { (Rails.env if defined?(Rails.env)) || ENV["RAILS_ENV"] || ENV["RACK_ENV"] } DEFAULT_ENV = -> { RAILS_ENV.call || "default_env" } # Establishes the connection to the database. Accepts a hash as input where |