From 48f569ee079d84570f79fef5a1bfa1599cc9d70c Mon Sep 17 00:00:00 2001 From: MS Date: Tue, 11 May 2021 09:55:25 +0200 Subject: fix condition check --- talermerchantdemos/httpcommon/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'talermerchantdemos/httpcommon/__init__.py') diff --git a/talermerchantdemos/httpcommon/__init__.py b/talermerchantdemos/httpcommon/__init__.py index 9708721..6ff4696 100644 --- a/talermerchantdemos/httpcommon/__init__.py +++ b/talermerchantdemos/httpcommon/__init__.py @@ -38,7 +38,7 @@ def exception_handler(func): @exception_handler def backend_post(backend_url, endpoint, json, auth_token=None): headers = dict() - if auth_token is not None: + if auth_token: headers["Authorization"] = "Bearer " + auth_token final_url = urljoin(backend_url, endpoint) print("POSTing to: " + final_url) -- cgit v1.2.3