From e03c332d56911a3fc21408c226ea5af17d8ec472 Mon Sep 17 00:00:00 2001 From: Rohit Yadav Date: Wed, 19 Feb 2020 12:52:36 +0530 Subject: [PATCH] permission: read cookie from both default and /client path Signed-off-by: Rohit Yadav --- ui/src/permission.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/src/permission.js b/ui/src/permission.js index 557a5a1c84e..bf437205b85 100644 --- a/ui/src/permission.js +++ b/ui/src/permission.js @@ -34,7 +34,7 @@ router.beforeEach((to, from, next) => { // start progress bar NProgress.start() to.meta && (typeof to.meta.title !== 'undefined' && setDocumentTitle(`${to.meta.title} - ${domTitle}`)) - const validLogin = Vue.ls.get(ACCESS_TOKEN) || Cookies.get('sessionkey') || Cookies.get('userid') + const validLogin = Vue.ls.get(ACCESS_TOKEN) || Cookies.get('userid') || Cookies.get('userid', { path: '/client' }) if (validLogin) { if (to.path === '/user/login') { next({ path: '/dashboard' })