Remove unused variable

This commit is contained in:
Timotej Lazar 2024-01-16 21:51:47 +01:00
parent d3d72791cf
commit f38fc807aa

View file

@ -95,19 +95,20 @@ if __name__ == '__main__':
request = json.loads(r.text)
request['AuthenticationToken'] = token
request['CertificatePublicKey'] = args.cert
# keep signing whatever they send us
while True:
for name in ('AttachmentHashes', 'XmlHashes'):
if request.get(name) is not None:
request[f'Signed{name}'] = [sign(e, args.key, pin, engine=args.engine) for e in request[name]]
d = json.dumps(request)
d = d.encode()
r = session.put(f'{url}signatures/{request["SignatureRequestId"]}',
headers=headers | {'Content-Type': 'application/json; charset=utf-8'},
data=json.dumps(request).encode())
if not r.text:
break
request |= json.loads(r.text)
except Exception as ex:
print(ex, file=sys.stderr)
input('press enter to exit') # don’t close terminal immediately on fail