mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-07-02 10:38:16 +00:00
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:
parent
e6583f7824
commit
4f2d2ca746
1 changed files with 4 additions and 1 deletions
|
|
@ -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);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue