Default to estimating 1 gwei for empty blocks.

To avoid estimating 0 gwei on low-traffic private networks.
feature/default_network_editable
Dan Finlay 7 years ago committed by GitHub
parent f441bb7248
commit 34826d18aa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      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))

Loading…
Cancel
Save