Skip to content

Commit

Permalink
guard insead
Browse files Browse the repository at this point in the history
  • Loading branch information
bdraco committed Oct 1, 2024
1 parent 66aa32d commit 8a7392b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion aiohttp/client_reqrep.py
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,7 @@ def update_headers(self, headers: Optional[LooseHeaders]) -> None:
assert netloc is not None
# See https://github.com/aio-libs/aiohttp/issues/3636.
if netloc[-1] == ".":
netloc = netloc[:-1]
netloc = netloc.rstrip(".")
explicit_port = self.url.explicit_port
if explicit_port is not None and not self.url.is_default_port():
netloc = f"{netloc}:{explicit_port}"
Expand Down

0 comments on commit 8a7392b

Please sign in to comment.