summaryrefslogtreecommitdiff
path: root/lib/chef/cookbook_version.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/cookbook_version.rb')
-rw-r--r--lib/chef/cookbook_version.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/chef/cookbook_version.rb b/lib/chef/cookbook_version.rb
index 2291caabd8..778a6043bf 100644
--- a/lib/chef/cookbook_version.rb
+++ b/lib/chef/cookbook_version.rb
@@ -405,6 +405,7 @@ class Chef
records_by_pref[best_pref]
end
+
# Given a node, segment and path (filename or directory name),
# return the priority-ordered list of preference locations to
# look.
@@ -457,9 +458,9 @@ class Chef
end
def to_json(*a)
- result = to_hash
+ result = self.to_hash
result['json_class'] = self.class.name
- ::Chef::JSONCompat.to_json(result, *a)
+ result.to_json(*a)
end
def self.json_create(o)