Maybe something like https://github.com/cvan/galaxy-api/blob/master/views/game/featured.js#L97 ?

At the very least, you should put the `JSON.parse` in a `try catch` block