Add extra tests for transactions fields

master
Mark Veidemanis 3 years ago
parent c213fe9d5d
commit e3d3595efd
Signed by: m
GPG Key ID: 5ACFCEED46C0904F

@ -78,6 +78,10 @@ class Transactions(util.Base):
ts = data["timestamp"] ts = data["timestamp"]
txid = data["transaction_id"] txid = data["transaction_id"]
txtype = data["transaction_type"] txtype = data["transaction_type"]
if "amount" not in data:
return
if "currency" not in data:
return
amount = data["amount"] amount = data["amount"]
if amount <= 0: if amount <= 0:
self.log.info(f"Ignoring transaction with negative/zero amount: {txid}") self.log.info(f"Ignoring transaction with negative/zero amount: {txid}")

Loading…
Cancel
Save