1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00

Merge pull request #2899 from MetaMask/danfinlay-patch-1

Default to estimating 1 gwei for empty blocks.
This commit is contained in:
kumavis 2018-01-08 15:05:00 -08:00 committed by GitHub
commit f42a808bea
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -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))