fix issue with percentage bump

This commit is contained in:
Roman Storm 2020-05-08 12:03:33 -07:00
parent a49746180e
commit 685f3e69b4
No known key found for this signature in database
GPG Key ID: 522F2A785F34E71F

@ -7,7 +7,7 @@ class Sender {
this.web3 = web3
this.watherInterval = config.watherInterval
this.pendingTxTimeout = config.pendingTxTimeout
this.gasBumpPercentage = config.gasBumpPercentage
this.gasBumpPercentage = 100 + Number(config.gasBumpPercentage)
this.watcher()
}
@ -23,7 +23,7 @@ class Sender {
tx.gasPrice = toHex(BN.min(newGasPrice, maxGasPrice))
tx.date = Date.now()
await redisClient.set('tx:' + tx.nonce, JSON.stringify(tx) )
console.log('resubmitting with gas price', fromWei(tx.gasPrice.toString()))
console.log('resubmitting with gas price', fromWei(tx.gasPrice.toString(), 'gwei'), ' gwei')
this.sendTx(tx, null, 9999)
}
}