diff --git a/Library/Homebrew/cask/lib/hbc/cli/internal_stanza.rb b/Library/Homebrew/cask/lib/hbc/cli/internal_stanza.rb index 27f195a4d3aa3..bafaadc244b2c 100644 --- a/Library/Homebrew/cask/lib/hbc/cli/internal_stanza.rb +++ b/Library/Homebrew/cask/lib/hbc/cli/internal_stanza.rb @@ -48,7 +48,7 @@ def initialize(*) raise ArgumentError, <<~EOS Unknown/unsupported stanza: '#{stanza}' - Check cask reference for supported stanzas. + Check Cask reference for supported stanzas. EOS end @@ -74,8 +74,7 @@ def run value = value[artifact_name] if artifact_name end - if value.nil? || (value.respond_to?(:to_a) && value.to_a.empty?) || - (value.respond_to?(:to_s) && value.to_s == "{}") + if value.nil? || (value.respond_to?(:to_a) && value.to_a.empty?) stanza_name = artifact_name ? artifact_name : stanza raise CaskError, "no such stanza '#{stanza_name}' on Cask '#{cask}'" end