Making sure the sender address is oracle_address in fetchDynamicSwapPrice()

This commit is contained in:
Vivek Teega 2023-04-24 18:26:36 +00:00
parent ba80ae4e6a
commit a35b35d22e

View File

@ -271,6 +271,7 @@ def fetchDynamicSwapPrice(contractStructure, transaction_data, blockinfo):
# and receiver address should be contractAddress
try:
assert transaction_data['receiverAddress'] == contractStructure['contractAddress']
assert transaction_data['senderAddress'] == oracle_address
floData = json.loads(floData)
# Check if the contract name and address are right
assert floData['price-update']['contract-name'] == contractStructure['contractName']