mirror of
https://github.com/d0zingcat/gocryptotrader.git
synced 2026-05-24 07:26:47 +00:00
In the common package added JSONDecode error check. Added verbosity in SendHTTPGetRequest. Updated Nonce package function. Fixed issues in ItBit package and expanded test coverage.
This commit is contained in:
@@ -127,7 +127,7 @@ func (b *Bitstamp) GetTicker(currency string, hourly bool) (Ticker, error) {
|
||||
tickerEndpoint,
|
||||
common.StringToLower(currency),
|
||||
)
|
||||
return response, common.SendHTTPGetRequest(path, true, &response)
|
||||
return response, common.SendHTTPGetRequest(path, true, b.Verbose, &response)
|
||||
}
|
||||
|
||||
// GetOrderbook Returns a JSON dictionary with "bids" and "asks". Each is a list
|
||||
@@ -149,7 +149,7 @@ func (b *Bitstamp) GetOrderbook(currency string) (Orderbook, error) {
|
||||
common.StringToLower(currency),
|
||||
)
|
||||
|
||||
err := common.SendHTTPGetRequest(path, true, &resp)
|
||||
err := common.SendHTTPGetRequest(path, true, b.Verbose, &resp)
|
||||
if err != nil {
|
||||
return Orderbook{}, err
|
||||
}
|
||||
@@ -204,7 +204,7 @@ func (b *Bitstamp) GetTransactions(currencyPair string, values url.Values) ([]Tr
|
||||
values,
|
||||
)
|
||||
|
||||
return transactions, common.SendHTTPGetRequest(path, true, &transactions)
|
||||
return transactions, common.SendHTTPGetRequest(path, true, b.Verbose, &transactions)
|
||||
}
|
||||
|
||||
// GetEURUSDConversionRate returns the conversion rate between Euro and USD
|
||||
@@ -212,7 +212,7 @@ func (b *Bitstamp) GetEURUSDConversionRate() (EURUSDConversionRate, error) {
|
||||
rate := EURUSDConversionRate{}
|
||||
path := fmt.Sprintf("%s/%s", bitstampAPIURL, bitstampAPIEURUSD)
|
||||
|
||||
return rate, common.SendHTTPGetRequest(path, true, &rate)
|
||||
return rate, common.SendHTTPGetRequest(path, true, b.Verbose, &rate)
|
||||
}
|
||||
|
||||
// GetBalance returns full balance of currency held on the exchange
|
||||
|
||||
Reference in New Issue
Block a user