Add message when json is invalid

Hi!
I only added a simple alert message when the json is invalid, it isn't too pretty but is useful. 
It will be helpful when the user try to use this functionality and he doesn't know why it don't work (his json is invalid).