From 52ccea0e5ff56b3d26411dbd66133cf59b39ecca Mon Sep 17 00:00:00 2001 From: Neal Conner Date: Mon, 14 Oct 2019 12:24:24 -0400 Subject: [PATCH] Update Bitstamp to new Bitpay api version --- lib/plugins/ticker/bitstamp/bitstamp.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/plugins/ticker/bitstamp/bitstamp.js b/lib/plugins/ticker/bitstamp/bitstamp.js index dbb81e5e..1d5ac416 100644 --- a/lib/plugins/ticker/bitstamp/bitstamp.js +++ b/lib/plugins/ticker/bitstamp/bitstamp.js @@ -18,9 +18,9 @@ exports.ticker = function ticker (account, fiatCode, cryptoCode) { return getCurrencyRates(fiatCode, cryptoCode) } - return axios.get('https://bitpay.com/api/rates') + return axios.get('https://bitpay.com/rates') .then(response => { - const fxRates = response.data + const fxRates = response.data.data const usdRate = findCurrency(fxRates, 'USD') const fxRate = findCurrency(fxRates, fiatCode).div(usdRate)