@@ -127,7 +127,7 @@ 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− const message = err.message || '';
130+ const message = typeof err === 'string' ? err : err.message || '';
131131 const isKnownError = message.includes('known transaction: ');
132132 const isNonceError =
133133 message.includes("the tx doesn't have the correct nonce.") ||