mirror of
https://github.com/d0zingcat/gocryptotrader.git
synced 2026-06-06 07:26:47 +00:00
Offline worst case trade fees (#274)
* Really basic getSimulated fee function everywhere * Worst case fees for all exchanges * Adds tests, fixes comment spacing. Adds wrapper logic. Makes test api key var name consistent. Removes some okcoin ETT tests * Removes redundant functions * linting issues. Fixes introduces huobi issues * More linting * Stops trying to hide ETT problems, uses iota * Skips ETT tests for now
This commit is contained in:
@@ -259,6 +259,10 @@ func (g *Gemini) GetWebsocket() (*exchange.Websocket, error) {
|
||||
|
||||
// GetFeeByType returns an estimate of fee based on type of transaction
|
||||
func (g *Gemini) GetFeeByType(feeBuilder *exchange.FeeBuilder) (float64, error) {
|
||||
if (g.APIKey == "" || g.APISecret == "") && // Todo check connection status
|
||||
feeBuilder.FeeType == exchange.CryptocurrencyTradeFee {
|
||||
feeBuilder.FeeType = exchange.OfflineTradeFee
|
||||
}
|
||||
return g.GetFee(feeBuilder)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user