aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Finlay <542863+danfinlay@users.noreply.github.com>2018-01-09 06:58:38 +0800
committerGitHub <noreply@github.com>2018-01-09 06:58:38 +0800
commit34826d18aa0acbe06d5c27013f249fa7c664d072 (patch)
treeec9f35852ffa706293cc5f26b98c9bf80bc4d8dc
parentf441bb7248d4b62d0d96897817655d348db0c29b (diff)
downloadtangerine-wallet-browser-34826d18aa0acbe06d5c27013f249fa7c664d072.tar
tangerine-wallet-browser-34826d18aa0acbe06d5c27013f249fa7c664d072.tar.gz
tangerine-wallet-browser-34826d18aa0acbe06d5c27013f249fa7c664d072.tar.bz2
tangerine-wallet-browser-34826d18aa0acbe06d5c27013f249fa7c664d072.tar.lz
tangerine-wallet-browser-34826d18aa0acbe06d5c27013f249fa7c664d072.tar.xz
tangerine-wallet-browser-34826d18aa0acbe06d5c27013f249fa7c664d072.tar.zst
tangerine-wallet-browser-34826d18aa0acbe06d5c27013f249fa7c664d072.zip
Default to estimating 1 gwei for empty blocks.
To avoid estimating 0 gwei on low-traffic private networks.
-rw-r--r--app/scripts/metamask-controller.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/scripts/metamask-controller.js b/app/scripts/metamask-controller.js
index 66738db51..aa2dddf3d 100644
--- a/app/scripts/metamask-controller.js
+++ b/app/scripts/metamask-controller.js
@@ -492,7 +492,7 @@ module.exports = class MetamaskController extends EventEmitter {
const { recentBlocks } = recentBlocksController.store.getState()
const lowestPrices = recentBlocks.map((block) => {
if (!block.gasPrices) {
- return new BN(0)
+ return GWEI_BN
}
return block.gasPrices
.map(hexPrefix => hexPrefix.substr(2))