bsphere / node-gapitoken

Node.js Google API service account authorization
51 stars 19 forks source link

Catch JSON parsing error #6

Closed erlichmen closed 10 years ago

erlichmen commented 10 years ago

Google can something (in outage for example) return HTML(!) page(!!) instead of JSON result.

When this happens your entire server will crash and you will get the uncaughtException process event which is too high in the responsibility chain to handle the FAIL.