Jelajahi Sumber

[add] 修复ws升级报错日志~

bvbej 2 tahun lalu
induk
melakukan
658aa0d2a9
1 mengubah file dengan 0 tambahan dan 1 penghapusan
  1. 0 1
      pkg/websocket/peer/connect/acceptor.go

+ 0 - 1
pkg/websocket/peer/connect/acceptor.go

@@ -47,7 +47,6 @@ func (ws *wsAcceptor) Start(addr string, sessMgr *peer.SessionManager) error {
 		c, upgradeErr := upgrader.Upgrade(w, r, nil)
 		if upgradeErr != nil {
 			ws.logger.Sugar().Errorf("upgrade http failed: %s", upgradeErr)
-			w.WriteHeader(http.StatusNotFound)
 			return
 		}
 		sessMgr.Register <- peer.NewSession(newConnection(c, sessMgr))