#6930 - Revert/Undo rollback #299

Merged
jsegarra merged 2 commits from 6930_undo_rollback into dev 2024-04-17 11:04:48 +00:00
1 changed files with 3 additions and 7 deletions
Showing only changes of commit 37ad84f239 - Show all commits

View File

@ -23,13 +23,9 @@ export function useSession() {
}
function setToken(data) {
if (data.keepLogin) {
localStorage.setItem(TOKEN, data.token);
localStorage.setItem(TOKEN_MULTIMEDIA, data.tokenMultimedia);
} else {
sessionStorage.setItem(TOKEN, data.token);
sessionStorage.setItem(TOKEN_MULTIMEDIA, data.tokenMultimedia);
}
const storage = data.keepLogin ? localStorage : sessionStorage;
storage.setItem(TOKEN, data.token);
storage.setItem(TOKEN_MULTIMEDIA, data.tokenMultimedia);
}
async function destroyToken(url, storage, key) {
if (storage.getItem(key)) {