I have a response from the server:
"results": {
"231412354": [
{
"id": "11913258",
"name" : "dsa"
}
],
"546547654": [
{
"id": "11913258",
"name" : "dsa"
},
],
}
My model for deserializing
public partial class Welcome
{
public Dictionary<long, Result[]> Results { get; set; }
}
public partial class Result
{
public long Id { get; set; }
public string Name { get; set; }
}
But sometimes the server can return an empty result that will look like an array
"results": []
And i get an deserializing error, I tried to add null value handling and not required, maybe need to add a custom converter. Could I have help in this matter?