Added check for valid json
Merge pull request #5 from ricbra/check_response

Added check for valid json