use await in async proc

Co-authored-by: gabrielmer <101006718+gabrielmer@users.noreply.github.com>
This commit is contained in:
Sergei Tikhomirov 2024-12-17 19:24:24 +01:00
parent 4ad3bda6e2
commit 4c57cbca5e
1 changed files with 1 additions and 1 deletions

View File

@ -47,7 +47,7 @@ proc isEligibleTxId*(
var txReceipt: ReceiptObject var txReceipt: ReceiptObject
let txHash = TxHash.fromHex(byteutils.toHex(eligibilityProof.proofOfPayment.get())) let txHash = TxHash.fromHex(byteutils.toHex(eligibilityProof.proofOfPayment.get()))
try: try:
(tx, txReceipt) = waitFor getTxAndTxReceipt(txHash, web3) (tx, txReceipt) = await getTxAndTxReceipt(txHash, web3)
except ValueError: except ValueError:
let errorMsg = "Failed to fetch tx or tx receipt: " & getCurrentExceptionMsg() let errorMsg = "Failed to fetch tx or tx receipt: " & getCurrentExceptionMsg()
error "exception in isEligibleTxId", error = $errorMsg error "exception in isEligibleTxId", error = $errorMsg