handle bump gas price error
This commit is contained in:
parent
af65d78be9
commit
8d4bab7fc2
@ -300,8 +300,11 @@ class Transaction {
|
|||||||
console.log(
|
console.log(
|
||||||
`Gas price ${formatUnits(this.tx.gasPrice, 'gwei')} gwei is too low, increasing and retrying`,
|
`Gas price ${formatUnits(this.tx.gasPrice, 'gwei')} gwei is too low, increasing and retrying`,
|
||||||
)
|
)
|
||||||
this._increaseGasPrice()
|
if (this._increaseGasPrice()) {
|
||||||
return this._send()
|
return this._send()
|
||||||
|
} else {
|
||||||
|
throw new Error('Already at max gas price, but still not enough to submit the transaction')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this._hasError(message, sameTxErrors)) {
|
if (this._hasError(message, sameTxErrors)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user