Skip to content

Commit 664457d

Browse files
committed
Rescue HTTP::URI::InvalidError
With the v6 http gem changes, this exception changed. So, for this gem, we rescue both the v5 exception and the v6 exception and raise the exception namespaced to this gem.
1 parent 0aaec5f commit 664457d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/indieweb/endpoints/client.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ class Client
1313
# @raise [InvalidURIError]
1414
def initialize(url)
1515
@uri = HTTP::URI.parse(url)
16-
rescue Addressable::URI::InvalidURIError => e
16+
rescue Addressable::URI::InvalidURIError, HTTP::URI::InvalidError => e
1717
raise InvalidURIError, e
1818
end
1919

0 commit comments

Comments
 (0)