Fixing multiple redirects on logout (#771)
diff --git a/src/utils/request.js b/src/utils/request.js
index 9371aee..836f6bf 100644
--- a/src/utils/request.js
+++ b/src/utils/request.js
@@ -59,7 +59,9 @@
duration: 0
})
store.dispatch('Logout').then(() => {
- router.push({ path: '/user/login', query: { redirect: router.history.current.fullPath } })
+ if (router.history.current.path !== '/user/login') {
+ router.push({ path: '/user/login', query: { redirect: router.history.current.fullPath } })
+ }
})
}
if (response.status === 404) {