I get json value in string format like:
{
"value": {},
"hasValue": false,
"isSuccess": true,
"isFail": false,
"messages": [],
"hasMessage": false
}
When I Deserialize json string to model, isSuccess = false
& isFail = true
.
JsonConvert.DeserializeObject<Shared.ApiResponse<MediatR.Unit>>(content);
Why this happens and how can I find problem?
I found that I must implement a custom JsonConvert. But as know, this works when I want to change some different types of value to Boolean (Like: yes, 1,…)