Prevent passing negative nonce because of prefetch

This commit is contained in:
Willian Mitsuda 2021-12-28 02:46:09 -03:00
parent 0c6137656f
commit 7d87345e98
1 changed files with 4 additions and 0 deletions

View File

@ -531,6 +531,10 @@ const getTransactionBySenderAndNonceFetcher = async ({
sender,
nonce,
}: TransactionBySenderAndNonceKey): Promise<string | undefined> => {
if (nonce < 0) {
return undefined;
}
const result = (await provider.send("ots_getTransactionBySenderAndNonce", [
sender,
nonce,