lib/onering/config.rb in onering-client-0.1.6 vs lib/onering/config.rb in onering-client-0.1.7

- old
+ new

@@ -25,12 +25,15 @@ @_configfiles_seen ||= Set.new() # only load files we haven't seen before (@_configfiles - @_configfiles_seen.to_a).each do |i| c = YAML.load(File.read(File.expand_path(i))) rescue {} - Onering::Logger.info("Loading config file at #{File.expand_path(i) rescue i}", "Onering::Config") unless c.empty? + + if c and not c.empty? + Onering::Logger.info("Loading config file at #{File.expand_path(i) rescue i}", "Onering::Config") + @_config.deep_merge!(c) + end - @_config.deep_merge!(c) @_configfiles_seen << i end # settings specified in the library override everything