summaryrefslogtreecommitdiff
path: root/lib/chef/json_compat.rb
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2016-03-14 10:34:33 -0700
committerLamont Granquist <lamont@scriptkiddie.org>2016-03-14 10:34:33 -0700
commit6705acbd7f301d1b04388043a3dfa0308655f120 (patch)
tree1e8a43b35ef1684a4b90578f1a6374758aa7e3c7 /lib/chef/json_compat.rb
parent365064280c93d519fdacbf032c0c21057e5549c9 (diff)
downloadchef-6705acbd7f301d1b04388043a3dfa0308655f120.tar.gz
chefstyle Style/AndOr fixes
this is part of our informal style guide, lets make it formal since clearly its not getting followed very well.
Diffstat (limited to 'lib/chef/json_compat.rb')
-rw-r--r--lib/chef/json_compat.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/json_compat.rb b/lib/chef/json_compat.rb
index 26d3751897..f8f05a0074 100644
--- a/lib/chef/json_compat.rb
+++ b/lib/chef/json_compat.rb
@@ -61,7 +61,7 @@ class Chef
# JSON gem requires top level object to be a Hash or Array (otherwise
# you get the "must contain two octets" error). Yajl doesn't impose the
# same limitation. For compatibility, we re-impose this condition.
- unless obj.kind_of?(Hash) or obj.kind_of?(Array)
+ unless obj.kind_of?(Hash) || obj.kind_of?(Array)
raise Chef::Exceptions::JSON::ParseError, "Top level JSON object must be a Hash or Array. (actual: #{obj.class})"
end