Skip to content

Commit b91fc64

Browse files
fix(client): send all configured auth headers (#643)
1 parent 89df119 commit b91fc64

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

src/finch/_client.py

+2-10
Original file line numberDiff line numberDiff line change
@@ -147,11 +147,7 @@ def qs(self) -> Querystring:
147147
@property
148148
@override
149149
def auth_headers(self) -> dict[str, str]:
150-
if self._bearer_auth:
151-
return self._bearer_auth
152-
if self._basic_auth:
153-
return self._basic_auth
154-
return {}
150+
return {**self._bearer_auth, **self._basic_auth}
155151

156152
@property
157153
def _bearer_auth(self) -> dict[str, str]:
@@ -455,11 +451,7 @@ def qs(self) -> Querystring:
455451
@property
456452
@override
457453
def auth_headers(self) -> dict[str, str]:
458-
if self._bearer_auth:
459-
return self._bearer_auth
460-
if self._basic_auth:
461-
return self._basic_auth
462-
return {}
454+
return {**self._bearer_auth, **self._basic_auth}
463455

464456
@property
465457
def _bearer_auth(self) -> dict[str, str]:

0 commit comments

Comments
 (0)