Migrate from gometalinter.v2 to golangci-lint (#249)

* Migrate from gometalinter.v2 to golangci-lint
This commit is contained in:
Adrian Gallagher
2019-03-01 16:10:29 +11:00
committed by GitHub
parent 81852f2e01
commit 7dcb1ab553
133 changed files with 2179 additions and 2204 deletions

View File

@@ -53,7 +53,7 @@ func (b *Bithumb) GetTradingPairs() ([]string, error) {
}
for x := range currencies {
currencies[x] = currencies[x] + "KRW"
currencies[x] += "KRW"
}
return currencies, nil
@@ -136,7 +136,7 @@ func (b *Bithumb) GetAccountInfo() (exchange.AccountInfo, error) {
for key, totalAmount := range bal.Total {
hold, ok := bal.InUse[key]
if !ok {
return info, fmt.Errorf("GetAccountInfo error - in use item not found for currency %s",
return info, fmt.Errorf("getAccountInfo error - in use item not found for currency %s",
key)
}
@@ -270,10 +270,10 @@ func (b *Bithumb) WithdrawCryptocurrencyFunds(withdrawRequest exchange.WithdrawR
// withdrawal is submitted
func (b *Bithumb) WithdrawFiatFunds(withdrawRequest exchange.WithdrawRequest) (string, error) {
if math.Mod(withdrawRequest.Amount, 1) != 0 {
return "", errors.New("KRW withdrawals do not support decimal places")
return "", errors.New("currency KRW does not support decimal places")
}
if withdrawRequest.Currency.String() != symbol.KRW {
return "", errors.New("Only KRW supported")
return "", errors.New("only KRW is supported")
}
bankDetails := fmt.Sprintf("%v_%v", withdrawRequest.BankCode, withdrawRequest.BankName)
bankAccountNumber := strconv.FormatFloat(withdrawRequest.BankAccountNumber, 'f', -1, 64)