Fix SimpleHttpClient not sending Accept header in `get_json` (#11677)
Co-authored-by: reivilibre <olivier@librepush.net>
This commit is contained in:
parent
7a1cefc6e3
commit
0201c6371c
|
@ -0,0 +1 @@
|
|||
Fix wrong variable reference in `SimpleHttpClient.get_json` that results in the absence of the `Accept` header in the request.
|
|
@ -588,7 +588,7 @@ class SimpleHttpClient:
|
|||
if headers:
|
||||
actual_headers.update(headers) # type: ignore
|
||||
|
||||
body = await self.get_raw(uri, args, headers=headers)
|
||||
body = await self.get_raw(uri, args, headers=actual_headers)
|
||||
return json_decoder.decode(body.decode("utf-8"))
|
||||
|
||||
async def put_json(
|
||||
|
|
Loading…
Reference in New Issue