Add login check
This commit is contained in:
parent
0ce2b2fa30
commit
57006dba22
5 changed files with 44 additions and 33 deletions
client/js/services
|
@ -27,9 +27,12 @@ mainApp.factory('Identity',[ '$http', '$cookies', function($http, $cookies){
|
|||
&& typeof tokenPart_1InCookie !== 'undefined'
|
||||
){
|
||||
|
||||
// If yes, put it into variables
|
||||
angular.extend(profile, profileInCookie);
|
||||
token=tokenPart_0InCookie+tokenPart_1InCookie;
|
||||
if(token!==null){
|
||||
// If yes, put it into variables
|
||||
angular.extend(profile, profileInCookie);
|
||||
token=tokenPart_0InCookie+tokenPart_1InCookie;
|
||||
|
||||
}
|
||||
|
||||
// Return I'm Login
|
||||
return true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue