diff --git a/src/JsonRpc/Serialization/Converters/ClientResponseConverter.cs b/src/JsonRpc/Serialization/Converters/ClientResponseConverter.cs index 3ede1c03d..e433d53f9 100644 --- a/src/JsonRpc/Serialization/Converters/ClientResponseConverter.cs +++ b/src/JsonRpc/Serialization/Converters/ClientResponseConverter.cs @@ -21,11 +21,14 @@ public override void WriteJson(JsonWriter writer, Response value, JsonSerializer writer.WriteValue("2.0"); writer.WritePropertyName("id"); writer.WriteValue(value.Id); + writer.WritePropertyName("result"); if (value.Result != null) { - writer.WritePropertyName("result"); serializer.Serialize(writer, value.Result); } + else{ + writer.WriteNull(); + } writer.WriteEndObject(); } }