aboutsummaryrefslogtreecommitdiffstats
path: root/app/scripts/controllers/currency.js
diff options
context:
space:
mode:
Diffstat (limited to 'app/scripts/controllers/currency.js')
-rw-r--r--app/scripts/controllers/currency.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/scripts/controllers/currency.js b/app/scripts/controllers/currency.js
index 1f20dc005..9e696ce55 100644
--- a/app/scripts/controllers/currency.js
+++ b/app/scripts/controllers/currency.js
@@ -8,7 +8,7 @@ class CurrencyController {
constructor (opts = {}) {
const initState = extend({
- currentCurrency: 'USD',
+ currentCurrency: 'usd',
conversionRate: 0,
conversionDate: 'N/A',
}, opts.initState)
@@ -45,10 +45,10 @@ class CurrencyController {
updateConversionRate () {
const currentCurrency = this.getCurrentCurrency()
- return fetch(`https://api.cryptonator.com/api/ticker/eth-${currentCurrency}`)
+ return fetch(`https://api.infura.io/v1/ticker/eth${currentCurrency}`)
.then(response => response.json())
.then((parsedResponse) => {
- this.setConversionRate(Number(parsedResponse.ticker.price))
+ this.setConversionRate(Number(parsedResponse.bid))
this.setConversionDate(Number(parsedResponse.timestamp))
}).catch((err) => {
if (err) {