fix: log udp client send failures when disconnected

Agent-Logs-Url: https://github.com/PepperDash/Essentials/sessions/761a7a78-c51f-474b-9000-baa9a232c0d0

Co-authored-by: jonnyarndt <21110580+jonnyarndt@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2026-05-15 20:09:51 +00:00 committed by GitHub
parent e6583f7824
commit 4f2d2ca746
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -336,7 +336,10 @@ namespace PepperDash.Core
var udpClient = client;
if (!IsConnected || udpClient == null)
{
Debug.Console(1, Debug.ErrorLogLevel.Warning, "GenericUdpClient '{0}': Cannot send bytes because the client is not connected", Key);
return;
}
udpClient.Send(bytes, bytes.Length);
}
@ -440,4 +443,4 @@ namespace PepperDash.Core
}
}
}
}
}