summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoah Kantrowitz <noah@coderanger.net>2017-04-10 22:34:39 -0700
committerNoah Kantrowitz <noah@coderanger.net>2017-04-10 22:34:39 -0700
commitd9a7c0863a67c066523584f11b7a1aeda60a2e05 (patch)
tree1ccf9a1ed4e7b725f3d2b99780fb3e149c00bed5
parent34a79a6cf8be2fe491e1651b5a61f02d4854c07b (diff)
downloadchef-d9a7c0863a67c066523584f11b7a1aeda60a2e05.tar.gz
Feed the rubocop.
Signed-off-by: Noah Kantrowitz <noah@coderanger.net>
-rw-r--r--lib/chef/provider/package.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/chef/provider/package.rb b/lib/chef/provider/package.rb
index 4a5a6e2e4d..4b73f47ed3 100644
--- a/lib/chef/provider/package.rb
+++ b/lib/chef/provider/package.rb
@@ -297,7 +297,11 @@ class Chef
def expand_options(options)
# its deprecated but still work to do to deprecate it fully
#Chef.deprecated(:package_misc, "expand_options is deprecated, use shell_out_compact or shell_out_compact_timeout instead")
- options ? " #{options.is_a?(Array) ? Shellwords.join(options) : options}" : ""
+ if options
+ " #{options.is_a?(Array) ? Shellwords.join(options) : options}"
+ else
+ ""
+ end
end
# Check the current_version against either the candidate_version or the new_version