diff --git a/packages/my-near-wallet/src/lib/my-near-wallet.ts b/packages/my-near-wallet/src/lib/my-near-wallet.ts index 5a3721567..5ac291a8d 100644 --- a/packages/my-near-wallet/src/lib/my-near-wallet.ts +++ b/packages/my-near-wallet/src/lib/my-near-wallet.ts @@ -116,11 +116,13 @@ const MyNearWallet: WalletBehaviourFactory< const block = await provider.block({ finality: "final" }); + const nonce = accessKey.access_key.nonce + BigInt(index + 1); + return nearAPI.transactions.createTransaction( account.accountId, nearAPI.utils.PublicKey.from(accessKey.public_key), transaction.receiverId, - accessKey.access_key.nonce + index + 1, + nonce, actions, nearAPI.utils.serialize.base_decode(block.header.hash) );