Skip to content

Commit

Permalink
perf: using None checking cookies instead of bool(encode#2875)
Browse files Browse the repository at this point in the history
  • Loading branch information
Tunglies committed Oct 14, 2023
1 parent e63b659 commit 45dd87c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion httpx/_client.py
Expand Up @@ -397,7 +397,7 @@ def _merge_cookies(
Merge a cookies argument together with any cookies on the client,
to create the cookies used for the outgoing request.
"""
if cookies or self.cookies:
if cookies is None or self.cookies is None:
merged_cookies = Cookies(self.cookies)
merged_cookies.update(cookies)
return merged_cookies
Expand Down

0 comments on commit 45dd87c

Please sign in to comment.