-
Notifications
You must be signed in to change notification settings - Fork 234
Open
Description
func (p *BitgetWsClient) Subscribe(list []model.SubscribeReq, listener common.OnReceive) {
var args []interface{}
for i := 0; i < len(list); i++ {
req := toUpperReq(list[i])
args = append(args, req)
p.bitgetBaseWsClient.ScribeMap[req] = listener
p.bitgetBaseWsClient.AllSuribe.Add(req)
// 删除这行重复的添加:args = append(args, req) 存在重复添加的问题
}
wsBaseReq := model.WsBaseReq{
Op: constants.WsOpSubscribe,
Args: args,
}
p.bitgetBaseWsClient.SendByType(wsBaseReq)
}
Metadata
Metadata
Assignees
Labels
No labels