Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Rubocop trailing / bug #13212

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ module Cask
# if it does not have a path component.
class HomepageUrlTrailingSlash < Base
include OnHomepageStanza
include HelperFunctions
extend AutoCorrector

MSG_NO_SLASH = "'%<url>s' must have a slash after the domain."
Expand All @@ -27,7 +28,8 @@ def on_homepage_stanza(stanza)

return unless url&.match?(%r{^.+://[^/]+$})

domain = URI(url_node.str_content).host
domain = URI(string_content(url_node, strip_dynamic: true)).host
return if domain.blank?

# This also takes URLs like 'https://example.org?path'
# and 'https://example.org#path' into account.
Expand Down