diff options
author | eileencodes <eileencodes@gmail.com> | 2018-02-22 15:39:11 -0500 |
---|---|---|
committer | eileencodes <eileencodes@gmail.com> | 2018-02-22 15:39:11 -0500 |
commit | edb61ca8dcb348563c227f2cfc8d8576216aa9f3 (patch) | |
tree | ca5b3f006541ae47965124fde0534b36ca606ef5 /railties/lib/rails/application | |
parent | f85c77bef9efd8ffa97a59e87320e55e486e30c2 (diff) | |
download | rails-edb61ca8dcb348563c227f2cfc8d8576216aa9f3.tar.gz rails-edb61ca8dcb348563c227f2cfc8d8576216aa9f3.tar.bz2 rails-edb61ca8dcb348563c227f2cfc8d8576216aa9f3.zip |
Revert "Reject empty database yamls"
This reverts commit 0979713abe2e22083e1beca01a1d113408c9ab36.
I originally wanted to delete the default config but found out it can
be called anything which means the code would blow up in unexpected
ways.
I thought "cool ill just delete the configs without dbs" and realized
that totally 100% breaks the three-tier config. So I'm reverting this
and the other commit.
Diffstat (limited to 'railties/lib/rails/application')
-rw-r--r-- | railties/lib/rails/application/configuration.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/lib/rails/application/configuration.rb b/railties/lib/rails/application/configuration.rb index 1bdaf91c46..8af364f1e4 100644 --- a/railties/lib/rails/application/configuration.rb +++ b/railties/lib/rails/application/configuration.rb @@ -179,7 +179,7 @@ module Rails values.reverse_merge!(shared) end end - loaded_yaml.reject! { |_, values| !values["database"] } + loaded_yaml.delete("default") Hash.new(shared).merge(loaded_yaml) elsif ENV["DATABASE_URL"] # Value from ENV['DATABASE_URL'] is set to default database connection |