From 095de51e605a9b88576e5e34fd55a6e32befa4eb Mon Sep 17 00:00:00 2001 From: Richard Moore Date: Fri, 2 Feb 2024 03:03:18 -0500 Subject: [PATCH] Add timeout to ContractTransactionResponse wait (#4497). --- src.ts/contract/wrappers.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src.ts/contract/wrappers.ts b/src.ts/contract/wrappers.ts index 3c056e632f..38ec9edf60 100644 --- a/src.ts/contract/wrappers.ts +++ b/src.ts/contract/wrappers.ts @@ -132,8 +132,8 @@ export class ContractTransactionResponse extends TransactionResponse { * and the transaction has not been mined, otherwise this will * wait until enough confirmations have completed. */ - async wait(confirms?: number): Promise { - const receipt = await super.wait(confirms); + async wait(confirms?: number, timeout?: number): Promise { + const receipt = await super.wait(confirms, timeout); if (receipt == null) { return null; } return new ContractTransactionReceipt(this.#iface, this.provider, receipt); }