From 1f0e72db99e8d409ba90c7cd875ff4a51e5a1157 Mon Sep 17 00:00:00 2001 From: Lamont Granquist Date: Thu, 14 Jan 2021 20:33:44 -0800 Subject: add test, fix node attributes deep merge bug Signed-off-by: Lamont Granquist --- lib/chef/node/attribute.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/chef/node/attribute.rb b/lib/chef/node/attribute.rb index 29b60a98d5..3383b3c7e5 100644 --- a/lib/chef/node/attribute.rb +++ b/lib/chef/node/attribute.rb @@ -596,7 +596,7 @@ class Chef merge_with.each do |key, merge_with_value| value = if merge_onto.key?(key) - deep_merge!(safe_dup(merge_onto[key]), merge_with_value) + deep_merge!(safe_dup(merge_onto.internal_get(key)), merge_with_value) else merge_with_value end @@ -632,7 +632,7 @@ class Chef merge_with.each do |key, merge_with_value| value = if merge_onto.key?(key) - hash_only_merge!(safe_dup(merge_onto[key]), merge_with_value) + hash_only_merge!(safe_dup(merge_onto.internal_get(key)), merge_with_value) else merge_with_value end -- cgit v1.2.1