calcurse-caldav: fix authentication in debug mode

Objects are reference in python, ".pop" was modifying the original
dictionary and thus breaking authentication by removing auth headers.

Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
This commit is contained in:
Bram 2018-12-03 04:53:05 +01:00 committed by Lukas Fleischer
parent 3f267d0473
commit 6f22e99ad5

View File

@ -220,7 +220,7 @@ def remote_query(conn, cmd, path, additional_headers, body):
if debug:
print("> {} {}".format(cmd, path))
headers_sanitized = headers
headers_sanitized = headers.copy()
if not debug_raw:
headers_sanitized.pop('Authorization', None)
print("> Headers: " + repr(headers_sanitized))