remove duplicate logging

This commit is contained in:
Sebastian Mark 2024-11-20 20:31:24 +01:00
parent c348049209
commit d975034680
2 changed files with 1 additions and 2 deletions

View file

@ -31,8 +31,6 @@ func SendPermanentBroadCastMessage() {
if time.Now().Sub(client.LastPong) > (10 * time.Second) { if time.Now().Sub(client.LastPong) > (10 * time.Second) {
// Remove unresponsive client // Remove unresponsive client
client.Conn.Close() client.Conn.Close()
delete(Clients, client.Conn.LocalAddr())
helper.Logger.Info("Client timed out", "lastPong", client.LastPong, "host", client.RealIP, "clients", len(Clients))
} }
} }
<-tick.C <-tick.C

View file

@ -5,6 +5,7 @@ import (
"net" "net"
"net/http" "net/http"
"sync" "sync"
"time"
"git.smsvc.net/pomodoro/GoTomato/internal/helper" "git.smsvc.net/pomodoro/GoTomato/internal/helper"
"git.smsvc.net/pomodoro/GoTomato/pkg/models" "git.smsvc.net/pomodoro/GoTomato/pkg/models"