diff options
author | Dan Finlay <dan@danfinlay.com> | 2016-11-09 00:39:41 +0800 |
---|---|---|
committer | Dan Finlay <dan@danfinlay.com> | 2016-11-09 00:39:41 +0800 |
commit | 7068d2e71c6d1ddb68095916dc16f3ff1f283590 (patch) | |
tree | 4bbd6d42cddb5c3fafc32dbbb2024d60408473ec /app/scripts/lib | |
parent | 6f39924e60545ca8ac19995a799c16d0dea11b04 (diff) | |
download | tangerine-wallet-browser-7068d2e71c6d1ddb68095916dc16f3ff1f283590.tar tangerine-wallet-browser-7068d2e71c6d1ddb68095916dc16f3ff1f283590.tar.gz tangerine-wallet-browser-7068d2e71c6d1ddb68095916dc16f3ff1f283590.tar.bz2 tangerine-wallet-browser-7068d2e71c6d1ddb68095916dc16f3ff1f283590.tar.lz tangerine-wallet-browser-7068d2e71c6d1ddb68095916dc16f3ff1f283590.tar.xz tangerine-wallet-browser-7068d2e71c6d1ddb68095916dc16f3ff1f283590.tar.zst tangerine-wallet-browser-7068d2e71c6d1ddb68095916dc16f3ff1f283590.zip |
Adjust gas buffer to be 20% over estimate
Diffstat (limited to 'app/scripts/lib')
-rw-r--r-- | app/scripts/lib/idStore.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/scripts/lib/idStore.js b/app/scripts/lib/idStore.js index 8c811a614..0ce91f471 100644 --- a/app/scripts/lib/idStore.js +++ b/app/scripts/lib/idStore.js @@ -287,9 +287,10 @@ IdentityStore.prototype.checkForDelegateCall = function (codeHex) { } } -const gasBuffer = new BN('200000', 10) IdentityStore.prototype.addGasBuffer = function (gas) { const bnGas = new BN(ethUtil.stripHexPrefix(gas), 16) + const five = new BN('5', 10) + const gasBuffer = bnGas.div(five) const correct = bnGas.add(gasBuffer) return ethUtil.addHexPrefix(correct.toString(16)) } |