Display "undefined" on toString of invalid JSON