diff --git a/Server/src/SOR.Gateway/Dispatch/MessageDispatcher.cs b/Server/src/SOR.Gateway/Dispatch/MessageDispatcher.cs index ddd659c..74b9628 100644 --- a/Server/src/SOR.Gateway/Dispatch/MessageDispatcher.cs +++ b/Server/src/SOR.Gateway/Dispatch/MessageDispatcher.cs @@ -158,10 +158,10 @@ public sealed class MessageDispatcher : IMessageDispatcher if (!remote.HasResponse) return null; - var payload = remote.ResponsePayload is { } element && - element.ValueKind is not JsonValueKind.Undefined and not JsonValueKind.Null + JsonElement? payload = remote.ResponsePayload is { } element && + element.ValueKind is not JsonValueKind.Undefined and not JsonValueKind.Null ? element - : null; + : (JsonElement?)null; return new ServerMessage( remote.ResponseType ?? "error",