summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2018-11-06 11:57:05 -0800
committerTim Smith <tsmith@chef.io>2018-11-07 10:15:05 -0800
commitb9198d055347a99502d1239b506b4cb8852645c2 (patch)
tree97c0b31c75850869f0fa3a0638679b90831155ee
parentbc79295c37e25cdc1b865f99c878a00c091f880d (diff)
downloadchef-b9198d055347a99502d1239b506b4cb8852645c2.tar.gz
resource inspector: don't convert nil to "nil" in default values
Only inspec the value if it isn't nil. Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r--lib/chef/resource_inspector.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/resource_inspector.rb b/lib/chef/resource_inspector.rb
index 1888f9a8bc..55a4d8e65d 100644
--- a/lib/chef/resource_inspector.rb
+++ b/lib/chef/resource_inspector.rb
@@ -31,7 +31,7 @@ module ResourceInspector
# code for the resource ourselves and just no
"lazy default"
else
- default.inspect # inspect properly returns symbols
+ default.inspect unless default.nil? # inspect properly returns symbols
end
end