linter: Enable gofumpt and run against codebase (#1848)

* linter: Enable gofumpt and run against codebase

* Address shazbert's nits

* gofumpt: Fix issues after rebase
This commit is contained in:
Adrian Gallagher
2025-03-18 10:23:16 +11:00
committed by GitHub
parent 748ed71455
commit f5faca2eb2
189 changed files with 1541 additions and 1104 deletions

View File

@@ -363,7 +363,8 @@ instruments:
LastUpdated: tick[j].Timestamp,
ExchangeName: b.Name,
OpenInterest: tick[j].OpenInterest,
AssetType: a})
AssetType: a,
})
if err != nil {
return err
}
@@ -412,7 +413,8 @@ func (b *Bitmex) UpdateOrderbook(ctx context.Context, p currency.Pair, assetType
orderbookNew, err := b.GetOrderbook(ctx,
OrderBookGetL2Params{
Symbol: fPair.String(),
Depth: 500})
Depth: 500,
})
if err != nil {
return book, err
}
@@ -639,7 +641,7 @@ func (b *Bitmex) SubmitOrder(ctx context.Context, s *order.Submit) (*order.Submi
return nil, err
}
var orderNewParams = OrderNewParams{
orderNewParams := OrderNewParams{
OrderType: s.Type.Title(),
Symbol: fPair.String(),
OrderQuantity: s.Amount,
@@ -671,7 +673,8 @@ func (b *Bitmex) ModifyOrder(ctx context.Context, action *order.Modify) (*order.
o, err := b.AmendOrder(ctx, &OrderAmendParams{
OrderID: action.OrderID,
OrderQty: int32(action.Amount),
Price: action.Price})
Price: action.Price,
})
if err != nil {
return nil, err
}
@@ -817,7 +820,7 @@ func (b *Bitmex) WithdrawCryptocurrencyFunds(ctx context.Context, withdrawReques
if err := withdrawRequest.Validate(); err != nil {
return nil, err
}
var r = UserRequestWithdrawalParams{
r := UserRequestWithdrawalParams{
Address: withdrawRequest.Crypto.Address,
Amount: withdrawRequest.Amount,
Currency: withdrawRequest.Currency.String(),