Closed Mephistofeles closed 3 years ago
Thanks. Looks right.
I think I'm going to delete all [DataContract]
and [DataMember]
attributes, they are a remnant from the past. I will replace them with '[JsonProperty]'.
And I think I can use [JsonIgnore]
on all the Id properties.
Would that cause problems for you?
No, JsonIgnore works fine.
As far as I know, Hue never returns id in the object's body. Id is returned as a dictionary key and it is set in this library accordingly, for example in HueClient-Lights:
I use the models from this library to recreate Hue API, and DataMember/JsonProperty attributes on these properties results in incorrect responses. This change should correct this without affecting other use cases.