mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-26 08:45:16 +00:00
if publicOnly is set, we should not connect user data stream
This commit is contained in:
parent
f190b1e66a
commit
5f18b89dfa
|
@ -519,9 +519,11 @@ func (environ *Environment) Connect(ctx context.Context) error {
|
|||
return err
|
||||
}
|
||||
|
||||
logger.Infof("connecting %s user data stream...", session.Name)
|
||||
if err := session.UserDataStream.Connect(ctx); err != nil {
|
||||
return err
|
||||
if !session.PublicOnly {
|
||||
logger.Infof("connecting %s user data stream...", session.Name)
|
||||
if err := session.UserDataStream.Connect(ctx); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user