When the request function is called and has some type of file reading error this error is not returned to the user app.
//line 31
function (error, response, body) {
if (!error && response.statusCode < 400) {
deferred.resolve(body);
} else {
deferred.reject(body);
// i think should be like -> deferred.reject(error);
}
};