summaryrefslogtreecommitdiff
path: root/src/home
diff options
context:
space:
mode:
Diffstat (limited to 'src/home')
-rw-r--r--src/home/api/web_api_client.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/home/api/web_api_client.py b/src/home/api/web_api_client.py
index 6f8ff27..4a9f4bc 100644
--- a/src/home/api/web_api_client.py
+++ b/src/home/api/web_api_client.py
@@ -168,13 +168,13 @@ class WebAPIClient:
raise ApiResponseError(r.status_code, 'TypeError', 'content-type is not application/json')
data = json.loads(r.text)
- if r.status_code != 200 or data['result'] == 'error':
+ if r.status_code != 200:
raise ApiResponseError(r.status_code,
data['error']['type'],
data['error']['message'],
data['error']['stacktrace'] if 'stacktrace' in data['error'] else None)
- return data['data'] if 'data' in data else True
+ return data['response'] if 'response' in data else True
finally:
for fname, f in fd.items():
# logger.debug(f'closing file {fname} (fd={f})')