forecast.io
forecast.io copied to clipboard
catch crashes parsin JSON
SyntaxError: Unexpected token F in JSON at position 0
at JSON.parse (<anonymous>)
at Request._callback (/node_modules/forecast.io/index.js:79:19)
I guess thats from 403 or something, but the app crashes.
Can you put try catch in JSON.parse so it doesnt crash the app. There is a fix from @danschumann in a pull request or you can just copy paste that 3 lines