mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-25 08:15:15 +00:00
Merge pull request #1429 from c9s/edwin/bybit/get-fee-rate-on-private-stream-only
This commit is contained in:
commit
2c7e42922b
|
@ -85,6 +85,12 @@ func NewStream(key, secret string, userDataProvider StreamDataProvider) *Stream
|
|||
stream.SetDispatcher(stream.dispatchEvent)
|
||||
stream.SetHeartBeat(stream.ping)
|
||||
stream.SetBeforeConnect(func(ctx context.Context) (err error) {
|
||||
if stream.PublicOnly {
|
||||
// we don't need the fee rate in the public stream.
|
||||
return
|
||||
}
|
||||
|
||||
// get account fee rate
|
||||
go stream.feeRateProvider.Start(ctx)
|
||||
|
||||
stream.marketsInfo, err = stream.streamDataProvider.QueryMarkets(ctx)
|
||||
|
|
Loading…
Reference in New Issue
Block a user