Skip to content

Commit

Permalink
Set InvalidURL init values as self params
Browse files Browse the repository at this point in the history
Co-authored-by: Sviatoslav Sydorenko (Святослав Сидоренко) <[email protected]>
  • Loading branch information
setla and webknjaz authored Jan 31, 2024
1 parent 6011ced commit 9e5de99
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions aiohttp/client_exceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,9 @@ class InvalidURL(ClientError, ValueError):
def __init__(self, url: StrOrURL, description: Union[str, None] = None) -> None:
# The type of url is not yarl.URL because the exception can be raised
# on URL(url) call
self._url = url
self._description = description

if description:
super().__init__(url, description)
else:
Expand Down

0 comments on commit 9e5de99

Please sign in to comment.