Close web socket watches correctly

This commit is contained in:
Jordan Liggitt
2015-12-10 14:20:46 -05:00
parent 7e4084c9cd
commit 993ef54e12

View File

@@ -88,6 +88,7 @@ type WatchServer struct {
// HandleWS implements a websocket handler. // HandleWS implements a websocket handler.
func (w *WatchServer) HandleWS(ws *websocket.Conn) { func (w *WatchServer) HandleWS(ws *websocket.Conn) {
defer ws.Close()
done := make(chan struct{}) done := make(chan struct{})
go func() { go func() {
var unused interface{} var unused interface{}