mirror of
https://gitea.osmocom.org/sim-card/pysim.git
synced 2026-07-09 22:58:49 +03:00
Revert "http_json_api: Only require Content-Type if response body is non-empty"
This reverts commit e0a9e73267.
This commit is contained in:
@@ -339,7 +339,7 @@ class JsonHttpApiClient():
|
||||
raise HttpStatusError(response)
|
||||
|
||||
resp_content_type = response.headers.get('Content-Type')
|
||||
if response.content and not resp_content_type.startswith(req_headers['Content-Type']):
|
||||
if not resp_content_type.startswith(req_headers['Content-Type']):
|
||||
raise HttpHeaderError(response)
|
||||
|
||||
if not response.headers.get('X-Admin-Protocol', 'gsma/rsp/v2.unknown').startswith('gsma/rsp/v2.'):
|
||||
|
||||
Reference in New Issue
Block a user