user can be authenticated when under old auth bearer token

This commit is contained in:
Kyle Spearrin 2017-01-23 23:51:12 -05:00
parent a9fbc92943
commit b0a7b88585
1 changed files with 10 additions and 8 deletions

View File

@ -89,14 +89,16 @@ function initUserService() {
var self = this;
self.tokenService.getToken(function (token) {
if (!token) {
callback(false);
}
else {
self.getUserId(function (userId) {
callback(userId !== null);
});
}
self.tokenService.getAuthBearer(function (authBearer) {
if (!token && !authBearer) {
callback(false);
}
else {
self.getUserId(function (userId) {
callback(userId !== null);
});
}
});
});
};
};