From 6864a010e0973e8e33f7dee52181322f2c90192e Mon Sep 17 00:00:00 2001 From: Alejo Acosta Date: Fri, 25 Oct 2024 14:55:09 -0300 Subject: [PATCH] add log typechecking to tx receipt constructor --- src/providers/provider.ts | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/providers/provider.ts b/src/providers/provider.ts index 9f2293cb..3e54c805 100644 --- a/src/providers/provider.ts +++ b/src/providers/provider.ts @@ -1234,11 +1234,7 @@ export class TransactionReceipt implements TransactionReceiptParams, Iterable { - return new Log(log, provider); - }), - ); + this.#logs = Object.freeze(Array.isArray(tx.logs) ? tx.logs.map((log) => new Log(log, provider)) : []); let gasPrice = BN_0; if (tx.effectiveGasPrice != null) {