From 0323aa3f80c38b03804f96f076471b1d8005c97c Mon Sep 17 00:00:00 2001 From: Juan Carlos Ruvalcaba Date: Fri, 30 Apr 2021 10:07:31 -0700 Subject: [PATCH] -Hope to fix login screen issue --- src/js/app.js | 1 + src/js/routes/login.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/js/app.js b/src/js/app.js index a8935e4..c3c6739 100644 --- a/src/js/app.js +++ b/src/js/app.js @@ -75,6 +75,7 @@ var app = new Framework7({ http.interceptors.response.use(undefined, function (err) { return new Promise(function (resolve, reject) { if (err.status === 401 && err.config && !err.config.__isRetryRequest) { + console.log("Auto saliendo..."); user.dispatch('logOut').then( () => { } ); //Untested } throw err; diff --git a/src/js/routes/login.js b/src/js/routes/login.js index c8af6c8..ed50eec 100644 --- a/src/js/routes/login.js +++ b/src/js/routes/login.js @@ -5,7 +5,7 @@ import user from '../stores/user.js'; function checkAuth( { resolve } ) { const router = this; if (user.getters.isLogged.value){ - router.navigate('/', { reloadCurrent: true }); + router.navigate('/', { clearPreviousHistory : true }); } else { if (router.currentRoute.name !== "login"){