Merge pull request #14302 from p-linnane/improve-sparke-audit

cask/audit: improve handling `nil` in sparkle
This commit is contained in:
Rylan Polster 2022-12-29 00:56:27 -05:00 committed by GitHub
commit b55f1dafe7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -582,8 +582,12 @@ module Cask
return if cask_min_os == min_os_string return if cask_min_os == min_os_string
min_os_symbol = cask_min_os&.to_sym.inspect || "no minimal OS version" min_os_symbol = if cask_min_os.present?
add_error "Upstream defined #{min_os_string.to_sym.inspect} as minimal OS version " \ cask_min_os.to_sym.inspect
else
"no minimum OS version"
end
add_error "Upstream defined #{min_os_string.to_sym.inspect} as the minimum OS version " \
"and the cask defined #{min_os_symbol}" "and the cask defined #{min_os_symbol}"
end end