@@ -7,10 +7,10 @@ import (
77 "time"
88
99 "github.com/centrifugal/centrifugo/v6/internal/logging"
10+ "github.com/centrifugal/centrifugo/v6/internal/websocket"
1011
1112 "github.com/centrifugal/centrifuge"
1213 "github.com/centrifugal/protocol"
13- "github.com/gorilla/websocket"
1414 "github.com/rs/zerolog/log"
1515)
1616
@@ -72,7 +72,7 @@ func (s *Handler) ServeHTTP(rw http.ResponseWriter, r *http.Request) {
7272 compressionLevel := s .config .CompressionLevel
7373 compressionMinSize := s .config .CompressionMinSize
7474
75- conn , err := s .upgrade .Upgrade (rw , r , nil )
75+ conn , _ , err := s .upgrade .Upgrade (rw , r , nil )
7676 if err != nil {
7777 log .Error ().Err (err ).Str ("transport" , transportName ).Msg ("websocket upgrade error" )
7878 return
@@ -104,7 +104,7 @@ func (s *Handler) ServeHTTP(rw http.ResponseWriter, r *http.Request) {
104104 if pingInterval > 0 {
105105 pongWait := pingInterval * 10 / 9
106106 _ = conn .SetReadDeadline (time .Now ().Add (pongWait ))
107- conn .SetPongHandler (func (string ) error {
107+ conn .SetPongHandler (func ([] byte ) error {
108108 _ = conn .SetReadDeadline (time .Now ().Add (pongWait ))
109109 return nil
110110 })
@@ -189,7 +189,6 @@ func (s *Handler) ServeHTTP(rw http.ResponseWriter, r *http.Request) {
189189 // https://github.com/gorilla/websocket/issues/448
190190 conn .SetPingHandler (nil )
191191 conn .SetPongHandler (nil )
192- conn .SetCloseHandler (nil )
193192 _ = conn .SetReadDeadline (time .Now ().Add (closeFrameWait ))
194193 for {
195194 if _ , _ , err := conn .NextReader (); err != nil {
0 commit comments