Commit 7261d312 authored by Adrien Dorsaz's avatar Adrien Dorsaz

v2: fix empty response parsing

parent 7084e7c2
......@@ -54,7 +54,10 @@ def get_crt(config, log=LOGGER):
resp = error.response
finally:
jws_nonce = resp.headers['Replay-Nonce']
return resp.status_code, resp.json(), resp.headers
if resp.text != '':
return resp.status_code, resp.json(), resp.headers
else:
return resp.status_code, json.dumps({}), resp.headers
# main code
adtheaders = {'User-Agent': 'acme-dns-tiny/2.0',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment