check attribute with value 0 exists or not returns false though it should return true as it exists

71 views Asked by At

I am trying to check if an attribute is in a json file or not but the attribute has a value of 0 so the following

status.bytes_read

returns false though it should return true as it exists what is the best way of handling this case?

0

There are 0 answers