feat: Phase 7.1 — 修改 ServeWS 签名,新增 tokenMgr 参数

- ServeWS 和 serveWS 函数新增 *auth.TokenManager 参数
- main.go 传入 tokenMgr 到 ServeWS
- handler_test.go 适配新签名
This commit is contained in:
hhs
2026-06-14 17:46:11 +08:00
parent d01aeaba68
commit 2aa3c98ab6
3 changed files with 8 additions and 5 deletions

View File

@@ -145,7 +145,7 @@ func main() {
convHandler.RegisterRoutes(apiGroup)
// WebSocket
r.GET("/ws", ws.ServeWS(sessionMgr, orch, cfg))
r.GET("/ws", ws.ServeWS(sessionMgr, orch, cfg, tokenMgr))
// HTTP Server
srv := &http.Server{