Skip to content

Commit

Permalink
Always return result property on success
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanbrandenburg committed Jan 21, 2020
1 parent 3bd6340 commit 66b13ce
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -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();
}
}
Expand Down

0 comments on commit 66b13ce

Please sign in to comment.