去除消息分流、设计不合理

This commit is contained in:
kercylan98 2023-05-19 15:46:02 +08:00
parent 3effa6bb91
commit f997332639
1 changed files with 1 additions and 5 deletions

View File

@ -76,11 +76,7 @@ func (slf *event) RegConnectionOpenedEvent(handle ConnectionOpenedEventHandle) {
}
func (slf *event) OnConnectionOpenedEvent(conn *Conn) {
if len(slf.diversionMessageChannels) == 0 {
log.Debug("Server", zap.String("ConnectionOpened", conn.GetID()))
} else {
log.Debug("Server", zap.String("ConnectionOpened", conn.GetID()), zap.Int("Node", slf.diversionConsistency.PickNode(conn.GetID())))
}
log.Debug("Server", zap.String("ConnectionOpened", conn.GetID()))
for _, handle := range slf.connectionOpenedEventHandles {
handle(slf.Server, conn)
}