Ensure we callback if the request was killed by the browser

This commit is contained in:
Johannes Zellner
2019-01-10 14:37:43 +01:00
parent b764f1c861
commit 661ce4fc1d

View File

@@ -33,7 +33,7 @@ angular.module('Application').service('Client', ['$http', '$interval', 'md5', 'N
// handle request killed by browser (eg. cors issue)
if (data === null && status === -1) {
client.offline = true;
return;
return callback(new ClientError('Request cancelled by browser'));
}
if (status === 401) return client.login();