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.
1 parent 70070be commit 0969e02Copy full SHA for 0969e02
lib/puppet/type/concat_file.rb
@@ -264,9 +264,9 @@ def should_content
264
end
265
266
def nested_merge(hash1, hash2)
267
- # If a hash is empty, simply return the other
268
- return hash1 if hash2.empty?
269
- return hash2 if hash1.empty?
+ # If a hash is nil or empty, simply return the other
+ return hash1 if hash2.nil? || hash2.empty?
+ return hash2 if hash1.nil? || hash1.empty?
270
271
# Unique merge for arrays
272
if hash1.is_a?(Array) && hash2.is_a?(Array)
0 commit comments