diff --git a/Library/Homebrew/cask/cask.rb b/Library/Homebrew/cask/cask.rb index 75a9e00b42..4a82c576f9 100644 --- a/Library/Homebrew/cask/cask.rb +++ b/Library/Homebrew/cask/cask.rb @@ -515,7 +515,7 @@ module Cask sig { returns(T.nilable(Homebrew::BundleVersion)) } def bundle_version @bundle_version ||= if (bundle = artifacts.find { |a| a.is_a?(Artifact::App) }&.target) && - (plist = Pathname("#{bundle}/Contents/Info.plist")) && plist.exist? + (plist = Pathname("#{bundle}/Contents/Info.plist")) && plist.exist? && plist.readable? Homebrew::BundleVersion.from_info_plist(plist) end end