summaryrefslogtreecommitdiff
path: root/lib/chef/provider/package/chocolatey.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/provider/package/chocolatey.rb')
-rw-r--r--lib/chef/provider/package/chocolatey.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/provider/package/chocolatey.rb b/lib/chef/provider/package/chocolatey.rb
index 29b9f0d322..a1ec4504a0 100644
--- a/lib/chef/provider/package/chocolatey.rb
+++ b/lib/chef/provider/package/chocolatey.rb
@@ -257,7 +257,7 @@ EOS
choco_command(*args).stdout.each_line do |line|
next if line.start_with?("Chocolatey v")
name, version = line.split("|")
- hash[name.downcase] = version.chomp
+ hash[name.downcase] = version&.chomp
end
hash
end