From f827bbd1c1f193e42a93778a187f80fae675212a Mon Sep 17 00:00:00 2001 From: dsm-ll Date: Mon, 2 Sep 2024 11:40:31 -0300 Subject: [PATCH] fix None from or to address --- src/fetch_disputables/ContractMonitor.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/fetch_disputables/ContractMonitor.py b/src/fetch_disputables/ContractMonitor.py index 6180621..2f272af 100644 --- a/src/fetch_disputables/ContractMonitor.py +++ b/src/fetch_disputables/ContractMonitor.py @@ -96,8 +96,8 @@ async def process_contract( to_address = tx["to"] if ( - from_address.lower() == contract_address.lower() - or to_address.lower() == contract_address.lower() + from_address is not None and from_address.lower() == contract_address.lower() + or to_address is not None and to_address.lower() == contract_address.lower() ): tx_hash = tx["hash"] receipt = w3.eth.get_transaction_receipt(tx_hash)