Fix not redirecting to login page after logging out

This commit is contained in:
kolaente 2020-05-09 22:31:33 +02:00
parent f878063015
commit 495350fa83
No known key found for this signature in database
GPG key ID: F40E70337AB24C9B

View file

@ -307,6 +307,7 @@
methods: { methods: {
logout() { logout() {
this.$store.dispatch('auth/logout') this.$store.dispatch('auth/logout')
router.push({name: 'login'})
}, },
loadNamespaces() { loadNamespaces() {
this.$store.dispatch('namespaces/loadNamespaces') this.$store.dispatch('namespaces/loadNamespaces')
@ -317,9 +318,10 @@
} }
}, },
doStuffAfterRoute(e) { doStuffAfterRoute(e) {
if(this.$store.state[IS_FULLPAGE]) { if (this.$store.state[IS_FULLPAGE]) {
this.$store.commit(IS_FULLPAGE, false) this.$store.commit(IS_FULLPAGE, false)
} }
this.loadNamespacesIfNeeded(e) this.loadNamespacesIfNeeded(e)
this.mobileMenuActive = false this.mobileMenuActive = false
this.userMenuActive = false this.userMenuActive = false