From 12748ffaa7b141eb83844b3d64151859b5a624a9 Mon Sep 17 00:00:00 2001 From: gcmutator <134900551+gcmutator@users.noreply.github.com> Date: Tue, 24 Jun 2025 15:35:13 +0800 Subject: [PATCH] chore: Update function comments (#1938) Signed-off-by: gcmutator <329964069@qq.com> --- currency/storage.go | 1 - exchanges/bybit/bybit_wrapper.go | 5 ++++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/currency/storage.go b/currency/storage.go index da3c1517..f9dc5757 100644 --- a/currency/storage.go +++ b/currency/storage.go @@ -581,7 +581,6 @@ func (s *Storage) SeedForeignExchangeRates() error { return s.updateExchangeRates(rates) } -// UpdateForeignExchangeRates sets exchange rates on the FX map func (s *Storage) updateExchangeRates(m map[string]float64) error { return s.fxRates.Update(m) } diff --git a/exchanges/bybit/bybit_wrapper.go b/exchanges/bybit/bybit_wrapper.go index 7f572d67..a62e58cd 100644 --- a/exchanges/bybit/bybit_wrapper.go +++ b/exchanges/bybit/bybit_wrapper.go @@ -1485,7 +1485,10 @@ func (by *Bybit) GetServerTime(ctx context.Context, _ asset.Item) (time.Time, er return info.TimeNano.Time(), err } -// transformInstrumentInfoSymbol converts GetInstrumentInfo symbol to one stored in config with proper delimiters +// transformSymbol returns a symbol with a delimiter added if missing +// * Spot and Coin-M add "_" +// * Options, USDC-M USDT-M add "-" +// * CrossMargin is left without a delimiter func (i *InstrumentInfo) transformSymbol(a asset.Item) string { switch a { case asset.Spot, asset.CoinMarginedFutures: