display message when error is a json object