Skip to content

Commit 2ba4a17

Browse files
committed
Fixed events when slicing immutable Result (ethers-io#3765).
1 parent 37bf4fb commit 2ba4a17

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src.ts/contract/contract.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -586,7 +586,7 @@ async function _emit(contract: BaseContract, event: ContractEventName, args: Arr
586586

587587
const count = sub.listeners.length;
588588
sub.listeners = sub.listeners.filter(({ listener, once }) => {
589-
const passArgs = args.slice();
589+
const passArgs = Array.from(args);
590590
if (payloadFunc) {
591591
passArgs.push(payloadFunc(once ? null: listener));
592592
}

0 commit comments

Comments
 (0)