I'm making a small app to allow users to look up books on openlibrary.org.
The app is still quite basic but works with looking up and parsing the json data. The issue I'm having is creating a check to make sure some data is there in the first place.
On openlibrary, if the ISBN number you search with exists, you get json data: https://openlibrary.org/api/books?bibkeys=0586057242&f&jscmd=data&format=json
If however you look up an ISBN that does not exist, you simply get an empty object returned to you as so: https://openlibrary.org/api/books?bibkeys=123&f&jscmd=data&format=json
How do I implement a check to see if there is actually data there to parse? At the moment my app doesn't crash if there is nothing there, it just doesn't do anything. I'd like to setup an error popup to the user when no data is found, but can not figure out how to do that initial check.