mirror of
https://github.com/m1k1o/neko.git
synced 2024-07-24 14:40:50 +12:00
add WebSocketHandler to WebSocket struct
This commit is contained in:
parent
bc38e036da
commit
9310bb5572
@ -10,7 +10,7 @@ import (
|
||||
|
||||
type WebSocket struct {
|
||||
id string
|
||||
ws WebSocketHandler
|
||||
ws *WebSocketHandler
|
||||
connection *websocket.Conn
|
||||
mu sync.Mutex
|
||||
}
|
||||
|
@ -142,6 +142,7 @@ func (ws *WebSocketHandler) Upgrade(w http.ResponseWriter, r *http.Request) erro
|
||||
|
||||
socket := &WebSocket{
|
||||
id: id,
|
||||
ws: ws,
|
||||
connection: connection,
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user