forked from verdnatura/salix-front
perf: #7190 remove comments
This commit is contained in:
parent
74eec098ac
commit
6018d51642
|
@ -90,6 +90,7 @@ export function useSession() {
|
||||||
await useRole().fetch();
|
await useRole().fetch();
|
||||||
await useUserConfig().fetch();
|
await useUserConfig().fetch();
|
||||||
await useTokenConfig().fetch();
|
await useTokenConfig().fetch();
|
||||||
|
|
||||||
startInterval();
|
startInterval();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -105,8 +106,6 @@ export function useSession() {
|
||||||
const renewPeriod = +sessionStorage.getItem('renewPeriod');
|
const renewPeriod = +sessionStorage.getItem('renewPeriod');
|
||||||
if (!renewPeriod) return;
|
if (!renewPeriod) return;
|
||||||
intervalId = setInterval(() => checkValidity(), renewPeriod * 1000);
|
intervalId = setInterval(() => checkValidity(), renewPeriod * 1000);
|
||||||
// JUST FOR TEST
|
|
||||||
// checkValidity();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function stopRenewer() {
|
function stopRenewer() {
|
||||||
|
@ -144,10 +143,8 @@ export function useSession() {
|
||||||
|
|
||||||
//COMMENT THIS IF JUST FOR TEST
|
//COMMENT THIS IF JUST FOR TEST
|
||||||
if (isNaN(renewPeriodInSeconds) || now <= maxDate) {
|
if (isNaN(renewPeriodInSeconds) || now <= maxDate) {
|
||||||
console.error('Token not renewed');
|
|
||||||
return (isCheckingToken = false);
|
return (isCheckingToken = false);
|
||||||
}
|
}
|
||||||
console.error('Token renewed');
|
|
||||||
|
|
||||||
await renewToken();
|
await renewToken();
|
||||||
isCheckingToken = false;
|
isCheckingToken = false;
|
||||||
|
|
Loading…
Reference in New Issue