mirror of
https://github.com/sparrowwallet/sparrow.git
synced 2024-11-04 21:36:45 +00:00
exchange source: use closing price where available
This commit is contained in:
parent
85eb4df7e9
commit
87e7a87e5e
1 changed files with 1 additions and 1 deletions
|
@ -101,7 +101,7 @@ public enum ExchangeSource {
|
||||||
Number[][] coinbaseData = httpClientService.requestJson(url, Number[][].class, Map.of("User-Agent", "Mozilla/4.0 (compatible; MSIE 9.0; Windows NT 6.1)", "Accept", "*/*"));
|
Number[][] coinbaseData = httpClientService.requestJson(url, Number[][].class, Map.of("User-Agent", "Mozilla/4.0 (compatible; MSIE 9.0; Windows NT 6.1)", "Accept", "*/*"));
|
||||||
for(Number[] price : coinbaseData) {
|
for(Number[] price : coinbaseData) {
|
||||||
Date date = new Date(price[0].longValue() * 1000);
|
Date date = new Date(price[0].longValue() * 1000);
|
||||||
historicalRates.put(DateUtils.truncate(date, Calendar.DAY_OF_MONTH), price[3].doubleValue());
|
historicalRates.put(DateUtils.truncate(date, Calendar.DAY_OF_MONTH), price[4].doubleValue());
|
||||||
}
|
}
|
||||||
} catch(Exception e) {
|
} catch(Exception e) {
|
||||||
if(log.isDebugEnabled()) {
|
if(log.isDebugEnabled()) {
|
||||||
|
|
Loading…
Reference in a new issue