diff --git a/tableauserverclient/server/endpoint/endpoint.py b/tableauserverclient/server/endpoint/endpoint.py index b532abfcb..c90b91004 100644 --- a/tableauserverclient/server/endpoint/endpoint.py +++ b/tableauserverclient/server/endpoint/endpoint.py @@ -13,11 +13,13 @@ def __init__(self, parent_srv): @staticmethod def _make_common_headers(auth_token, content_type): - retval = {} + headers = {} if auth_token is not None: - retval['x-tableau-auth'] = auth_token + headers['x-tableau-auth'] = auth_token if content_type is not None: - retval['content-type'] = content_type + headers['content-type'] = content_type + + return headers def _make_request(self, method, url, content=None, request_object=None, auth_token=None, content_type=None): if request_object is not None: