Skip to content

Commit

Permalink
Fix crash when encountering invalid URL (#26814)
Browse files Browse the repository at this point in the history
  • Loading branch information
ClearlyClaire committed Sep 19, 2023
1 parent 5aba8e7 commit 1afae8c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/lib/tag_manager.rb
Expand Up @@ -28,7 +28,7 @@ def local_url?(url)
domain = uri.host + (uri.port ? ":#{uri.port}" : '')

TagManager.instance.web_domain?(domain)
rescue Addressable::URI::InvalidURIError
rescue Addressable::URI::InvalidURIError, IDN::Idna::IdnaError
false
end
end

0 comments on commit 1afae8c

Please sign in to comment.