Occasionally an error will occur on the requests so we need to check for an error as well as the 200 in the response. If we don't check for the error you can get a "cannot read statusCode of undefined" error and the app crashes.
check for error before looking at response
Could you remove this?
Looks like you need a newline here
sorry about that - fixed!
NPM package has been published as well