From 21eb12ffbc5088632c1680f376898ffddfcb8abb Mon Sep 17 00:00:00 2001 From: Abhipsa Misra Date: Fri, 4 Jun 2021 10:35:38 -0700 Subject: [PATCH] fix --- .../TemperatureController/SystemTextJsonPayloadSerializer.cs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/iothub/device/samples/convention-based-samples/TemperatureController/SystemTextJsonPayloadSerializer.cs b/iothub/device/samples/convention-based-samples/TemperatureController/SystemTextJsonPayloadSerializer.cs index 0f71e39c59..c3cad86935 100644 --- a/iothub/device/samples/convention-based-samples/TemperatureController/SystemTextJsonPayloadSerializer.cs +++ b/iothub/device/samples/convention-based-samples/TemperatureController/SystemTextJsonPayloadSerializer.cs @@ -33,9 +33,7 @@ public override string SerializeToString(object objectToSerialize) /// public override T DeserializeToType(string stringToDeserialize) { - var jsonOptions = new JsonSerializerOptions(); - jsonOptions.Converters.Add(new ObjectToInferredTypesConverter()); - return JsonSerializer.Deserialize(stringToDeserialize, jsonOptions); + return JsonSerializer.Deserialize(stringToDeserialize); } ///