Fix reload issue

This commit is contained in:
Pierre HUBERT 2021-02-14 19:29:29 +01:00
parent 5011d3e6ff
commit 562293a2e0
2 changed files with 3 additions and 3 deletions

View File

@ -175,7 +175,7 @@ const APIClient = {
//Log error
ComunicWeb.debug.logMessage("Got an error in a XHR request! \n Request URL: "+requestURL+" \n Response : "+apiXHR.responseText);
if (result.error.code == 412) {
if (result.error.code == 412 && signed_in()) {
UserLogin.__userLogin = false;
ComunicWeb.user.loginTokens.deleteLoginTokens();
System.restart();

View File

@ -102,7 +102,7 @@ function openGroupPage(info){
* @return {Boolean} True if the user is signed in / false else
*/
function signed_in(){
return ComunicWeb.user.userLogin.getUserLoginState();
return UserLogin.getUserLoginState();
}
/**
@ -112,7 +112,7 @@ function signed_in(){
* @return {Integer} The ID of the user
*/
function userID(){
return ComunicWeb.user.userLogin.getUserID();
return UserLogin.getUserID();
}
/**