优化websocket服务

This commit is contained in:
boyce
2019-01-26 16:47:15 +08:00
parent e71c339f0d
commit 423da02940
2 changed files with 7 additions and 1 deletions

View File

@@ -83,7 +83,7 @@ func (slf *WebsocketServer) Init(pattern string, port uint16, messageReciver IMe
slf.mapClient = make(map[uint64]*WSClient)
slf.messageReciver = messageReciver
http.HandleFunc("/ws", slf.wsHandler)
http.HandleFunc(slf.pattern, slf.wsHandler)
}
func (slf *WebsocketServer) startListen() {