We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 699199b commit e6f5d00Copy full SHA for e6f5d00
server/server.go
@@ -31,12 +31,11 @@ func (s *Server) Method(n string, h MethodHandler) {
31
}
32
33
func (s *Server) Listen(ipPort string) {
34
- http.HandleFunc("/websocket", s.handler)
+ http.HandleFunc("/websocket", s.Handler)
35
http.ListenAndServe(ipPort, nil)
36
37
38
-// create websocket connection from http handler and runs the websocket handler
39
-func (s *Server) handler(w http.ResponseWriter, r *http.Request) {
+func (s *Server) Handler(w http.ResponseWriter, r *http.Request) {
40
ws, err := s.upgrader.Upgrade(w, r, nil)
41
42
if err != nil {
0 commit comments