Skip to content

Commit

Permalink
Merge pull request #4907 from bigscoop/bitstamp-minor-fix
Browse files Browse the repository at this point in the history
[bitstamp] Replace array with List in api call
  • Loading branch information
timmolter authored Jun 13, 2024
2 parents 6352da0 + 9c963b9 commit b3c2811
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package org.knowm.xchange.bitstamp;

import java.io.IOException;
import java.util.Arrays;
import java.util.List;
import java.util.UUID;
import java.util.concurrent.TimeUnit;
import org.knowm.xchange.BaseExchange;
Expand Down Expand Up @@ -68,8 +68,8 @@ public SynchronizedValueFactory<String> getTimestampFactory() {
public void remoteInit() throws IOException, ExchangeException {
BitstampMarketDataServiceRaw dataService =
(BitstampMarketDataServiceRaw) this.marketDataService;
BitstampPairInfo[] bitstampPairInfos = dataService.getTradingPairsInfo();
List<BitstampPairInfo> bitstampPairInfos = dataService.getTradingPairsInfo();
exchangeMetaData =
BitstampAdapters.adaptMetaData(Arrays.asList(bitstampPairInfos), exchangeMetaData);
BitstampAdapters.adaptMetaData(bitstampPairInfos, exchangeMetaData);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ BitstampTransaction[] getTransactions(

@GET
@Path("trading-pairs-info/")
BitstampPairInfo[] getTradingPairsInfo() throws IOException, BitstampException;
List<BitstampPairInfo> getTradingPairsInfo() throws IOException, BitstampException;

class Pair {
public final CurrencyPair pair;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ public BitstampTransaction[] getTransactions(CurrencyPair pair, @Nullable Bitsta
}
}

public BitstampPairInfo[] getTradingPairsInfo() throws IOException {
public List<BitstampPairInfo> getTradingPairsInfo() throws IOException {
try {
return bitstampV2.getTradingPairsInfo();
} catch (BitstampException e) {
Expand Down

0 comments on commit b3c2811

Please sign in to comment.