feature/default_network_editable
Kevin Serrano 8 years ago
parent a612fcee64
commit 22528002e1
  1. 2
      app/scripts/lib/config-manager.js
  2. 4
      app/scripts/metamask-controller.js
  3. 2
      ui/app/actions.js
  4. 2
      ui/app/reducers/metamask.js

@ -296,7 +296,7 @@ ConfigManager.prototype.updateConversionRate = function () {
ConfigManager.prototype.setConversionPrice = function(price) {
var data = this.getData()
data.conversionRate = Number(parsedResponse.ticker.price)
data.conversionRate = Number(price)
this.setData(data)
}

@ -260,7 +260,9 @@ module.exports = class MetamaskController {
clearInterval(this.conversionInterval)
}
this.conversionInterval = setInterval(() => {
console.log("Updated currency!")
console.log('=================')
console.log('Updated currency!')
console.log('=================')
this.configManager.updateConversionRate()
}, 1000)
}

@ -220,7 +220,7 @@ function setCurrentFiat (fiat) {
currentFiat: data.currentFiat,
conversionRate: data.conversionRate,
conversionDate: data.conversionDate,
}
},
})
})
}

@ -110,7 +110,7 @@ function reduceMetamask (state, action) {
return extend(metamaskState, { identities })
case actions.SET_CURRENT_FIAT:
return extend(metaMaskState, {
return extend(metamaskState, {
currentFiat: action.value.currentFiat,
conversionRate: action.value.conversionRate,
conversionDate: action.value.conversionDate,

Loading…
Cancel
Save