Skip to content

Commit

Permalink
change mut arg on None and added checker is None
Browse files Browse the repository at this point in the history
  • Loading branch information
ArtemIsmagilov authored and tobixen committed Jun 12, 2024
1 parent 2a0e159 commit 7681cd9
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion caldav/davclient.py
Original file line number Diff line number Diff line change
Expand Up @@ -618,11 +618,14 @@ def request(
url: str,
method: str = "GET",
body: str = "",
headers: Mapping[str, str] = {},
headers: Mapping[str, str] = None,
) -> DAVResponse:
"""
Actually sends the request, and does the authentication
"""
if headers is None:
headers = {}

combined_headers = self.headers.copy()
combined_headers.update(headers)
if (body is None or body == "") and "Content-Type" in combined_headers:
Expand Down

0 comments on commit 7681cd9

Please sign in to comment.