Skip to content

Commit

Permalink
remove excess logging
Browse files Browse the repository at this point in the history
  • Loading branch information
mholtzman committed Dec 5, 2021
1 parent 9c3e672 commit 96bf099
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions main/chains/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,28 +75,29 @@ class ChainConnection extends EventEmitter {
this.chainConfig.setHardfork(Hardfork.London)
}
} catch (e) {
log.error(`could not load EIP-1559 fee market for chain ${this.chainId}`, e)
feeMarket = null
// log.error(`could not load EIP-1559 fee market for chain ${this.chainId}`, e)
}
}

try {
if (feeMarket) {
const gasPrice = parseInt(feeMarket.maxBaseFeePerGas) + parseInt(feeMarket.maxPriorityFeePerGas)

store.setGasFees(this.type, this.chainId, feeMarket)
store.setGasPrices(this.type, this.chainId, { fast: addHexPrefix(gasPrice.toString(16)) })
store.setGasDefault(this.type, this.chainId, 'fast')
} else {
const gas = await gasCalculator.getGasPrices()
const customLevel = store('main.networksMeta', this.type, this.chainId, 'gas.price.levels.custom')

store.setGasFees(this.type, this.chainId, null)
store.setGasPrices(this.type, this.chainId, {
...gas,
custom: customLevel || gas.fast
})
}

store.setGasFees(this.type, this.chainId, feeMarket)

accounts.updatePendingFees(this.chainId)
} catch (e) {
log.error(`could not update gas prices for chain ${this.chainId}`, { feeMarket, chainConfig: this.chainConfig }, e)
Expand Down

0 comments on commit 96bf099

Please sign in to comment.