fix: replace break with return in error handling for ws client

- pkg/protocol/ws/client.go
  - Changed `break` to `return` to ensure proper error handling flow in `client.go`.

  this bug was causing the CPU usage to go very high from fmt.Errorf statements. changed them to errorf.E so they printed and were visible.
This commit is contained in:
2025-08-18 20:15:38 +01:00
parent a51e86f4c4
commit 287af9dc81

View File

@@ -273,7 +273,7 @@ func (r *Client) ConnectWithTLS(
); err != nil { ); err != nil {
r.ConnectionError = err r.ConnectionError = err
r.Close() r.Close()
break return
} }
message := buf.Bytes() message := buf.Bytes()
var t string var t string