@@ -127,20 +127,20 @@ const sendSignedTransaction = (web3, stx, doubtNonceError) => {
127127 // if there's a nonce error, but we used the gas tank, it's likely
128128 // that it's because the tank already submitted our transaction.
129129 // we just wait for first confirmation here.
130− console.error(err);
131− const isKnownError = (err.message || '').includes(
132− 'known transaction: '
133− );
134− const isNonceError = (err.message || '').includes(
135− "the tx doesn't have the correct nonce."
136− );
130+ const message = err.message || '';
131+ const isKnownError = message.includes('known transaction: ');
132+ const isNonceError =
133+ message.includes("the tx doesn't have the correct nonce.") ||
134+ message.includes('nonce too low');
137135 if (isKnownError || (doubtNonceError && isNonceError)) {
138136 console.log(
139− 'tx send error likely from gas tank submission, ignoring'
137+ 'tx send error likely from gas tank submission, ignoring:',
138+ message
140139 );
141140 const txHash = web3.utils.keccak256(rawTx);
142141 resolve(txHash);
143142 } else {
143+ console.error(err);
144144 reject(err.message || 'Transaction sending failed!');
145145 }
146146 });