Do more error checking in fetchJson() to simplify method calls