abp
abp copied to clipboard
ignore null attributes in api response
Hello
It is possible to configure a dto object so that the api does not send null attributes in the response.
Hi @erojasd,
You cannot configure a dynamic DTO to suppress the null properties. It is not related with ABP.
Here is my suggestion:
You can return a json string by change some options in JsonSerializerSettings. Please look at: https://www.newtonsoft.com/json/help/html/NullValueHandlingIgnore.htm