From 95fa33a488b3b51b03c9589cf8d5942644044f48 Mon Sep 17 00:00:00 2001 From: Marc Baloup Date: Mon, 20 Mar 2023 22:49:57 +0100 Subject: [PATCH] Fix missing return statement. Was logging an error even if connection succeed. --- .../java/fr/pandacube/lib/ws/client/AbstractClientWS.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pandalib-ws-client/src/main/java/fr/pandacube/lib/ws/client/AbstractClientWS.java b/pandalib-ws-client/src/main/java/fr/pandacube/lib/ws/client/AbstractClientWS.java index e39853d..16ff2a7 100644 --- a/pandalib-ws-client/src/main/java/fr/pandacube/lib/ws/client/AbstractClientWS.java +++ b/pandalib-ws-client/src/main/java/fr/pandacube/lib/ws/client/AbstractClientWS.java @@ -106,13 +106,15 @@ public abstract class AbstractClientWS implements AbstractWS { isConnecting = false; if (ws != null) { socket.set(ws); + return; } } if (ex instanceof IOException) { reconnectIfNecessary(); } else { - logError("Error connecting (not trying to reconnect even if asked): ", ex); + autoReconnect = false; + logError("Error connecting (not trying to reconnect even if asked)", ex); } }); }