1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00

Use error.value.message with error.message as fallback (#8825)

* Use  over the whole stringified error object which doesn't show the actual error message that is set as the

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
* Feedback commit
This commit is contained in:
Thomas Huang 2020-06-16 16:21:56 -07:00 committed by GitHub
parent 3b2bbe0705
commit 792366a20f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -79,7 +79,7 @@ export default class PendingTransactionTracker extends EventEmitter {
try {
await this._resubmitTx(txMeta, blockNumber)
} catch (err) {
const errorMessage = err.message.toLowerCase()
const errorMessage = err.value?.message?.toLowerCase() || err.message.toLowerCase()
const isKnownTx = (
// geth
errorMessage.includes('replacement transaction underpriced') ||