From 1a78c8fca1362cc39e4f4a450313d494a0cabb54 Mon Sep 17 00:00:00 2001 From: MrZYX Date: Wed, 18 May 2011 19:22:15 +0200 Subject: [PATCH] whoops lets do a deep merge --- lib/app_config.rb | 2 +- script/get_config.rb | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/app_config.rb b/lib/app_config.rb index 77f1ef101..8577adfc4 100644 --- a/lib/app_config.rb +++ b/lib/app_config.rb @@ -35,7 +35,7 @@ class AppConfig end if File.exist? "#{Rails.root}/config/app_config.yml" all_envs_custom = load_config_yaml "#{Rails.root}/config/app_config.yml" - all_envs.merge!(all_envs_custom) + all_envs.deep_merge!(all_envs_custom) else unless Rails.env == "development" || Rails.env == "test" $stderr.puts "WARNING: No config/app_config.yml found! Look at config/app_config.yml.example for help." diff --git a/script/get_config.rb b/script/get_config.rb index fe0449297..759238f34 100755 --- a/script/get_config.rb +++ b/script/get_config.rb @@ -8,6 +8,7 @@ require 'yaml' require 'active_support/core_ext/class/attribute_accessors' require 'active_support/core_ext/hash/keys' +require 'active_support/core_ext/hash/deep_merge' class Rails def self.root