mirror of
https://github.com/ansible/awx.git
synced 2024-11-01 16:51:11 +03:00
use isEmpty check for valid object on session limit
This commit is contained in:
parent
4570535477
commit
2056ac16d5
@ -94,8 +94,7 @@ export default
|
||||
$rootScope.token_expires = null;
|
||||
$rootScope.login_username = null;
|
||||
$rootScope.login_password = null;
|
||||
clearTimeout($rootScope.idleTimer);
|
||||
clearTimeout($rootScope.endTimer);
|
||||
$rootScope.sessionTimer.expireSession();
|
||||
},
|
||||
|
||||
getLicense: function () {
|
||||
|
@ -21,7 +21,7 @@
|
||||
return config;
|
||||
},
|
||||
responseError: function(rejection){
|
||||
if(rejection.data.detail && rejection.data.detail === "Maximum per-user sessions reached"){
|
||||
if( !_.isEmpty(rejection.data.detail) && rejection.data.detail === "Maximum per-user sessions reached"){
|
||||
$rootScope.sessionTimer.expireSession('session_limit');
|
||||
return rejection;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user