Merge pull request #10455 from SeekingMeaning/cask-audit-verified

cask/audit: error if `verified` does not match, regardless of `url`
This commit is contained in:
Seeker 2021-01-29 16:18:06 -08:00 committed by GitHub
commit 24bbfffc61
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -433,9 +433,8 @@ module Cask
end end
def check_no_match def check_no_match
return if url_match_homepage?
return unless verified_present? return unless verified_present?
return if !url_match_homepage? && verified_matches_url? return if verified_matches_url?
add_error "Verified URL #{url_from_verified} does not match URL #{strip_url_scheme(cask.url.to_s)}. " \ add_error "Verified URL #{url_from_verified} does not match URL #{strip_url_scheme(cask.url.to_s)}. " \
"See https://github.com/Homebrew/homebrew-cask/blob/master/doc/cask_language_reference/stanzas/url.md#when-url-and-homepage-hostnames-differ-add-verified" "See https://github.com/Homebrew/homebrew-cask/blob/master/doc/cask_language_reference/stanzas/url.md#when-url-and-homepage-hostnames-differ-add-verified"