Skip to content

Commit

Permalink
Current network gas price in the menu bar (#692)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mathieu-Be authored Jan 20, 2022
1 parent 9d0e735 commit add1cbd
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion main/windows/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,8 @@ const api = {
this.gasObserver = store.observer(() => {
let title = ''
if (store('platform') === 'darwin' && store('main.menubarGasPrice')) {
const gasPrice = store('main.networksMeta.ethereum.1.gas.price.levels.fast')
const currentNetwork = store('main.currentNetwork');
const gasPrice = store('main.networksMeta.ethereum.' + currentNetwork.id + '.gas.price.levels.fast')
if (!gasPrice) return
const gasDisplay = Math.round(parseInt(gasPrice, 'hex') / 1000000000).toString()
title = gasDisplay // ɢ 🄶 Ⓖ ᴳᵂᴱᴵ
Expand Down

0 comments on commit add1cbd

Please sign in to comment.