Catch errors decoding JSON.