From a25ee424aacb212f43fb93fb3df00a10cb3b50fa Mon Sep 17 00:00:00 2001 From: Sebastian Mark Date: Wed, 20 Nov 2024 20:41:50 +0100 Subject: [PATCH] skip client after closing unresponsive client --- internal/websocket/broadcast.go | 1 + 1 file changed, 1 insertion(+) diff --git a/internal/websocket/broadcast.go b/internal/websocket/broadcast.go index b8333fd..2165787 100644 --- a/internal/websocket/broadcast.go +++ b/internal/websocket/broadcast.go @@ -25,6 +25,7 @@ func SendPermanentBroadCastMessage() { if time.Now().Sub(client.LastPong) > (10 * time.Second) { // Remove unresponsive client client.Conn.Close() + continue } err := client.SendMessage(websocket.TextMessage, jsonMessage) if err != nil {