fixed music player not stopping on logout
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
7f33b5d60b
commit
89607acaea
@ -53,7 +53,7 @@ export default {
|
|||||||
performLogout() {
|
performLogout() {
|
||||||
this.logoutProcessing = true;
|
this.logoutProcessing = true;
|
||||||
this.$api.performLogout().then(() => {
|
this.$api.performLogout().then(() => {
|
||||||
this.$store.dispatch('storeUserData', null).then(() => {
|
this.$store.dispatch('logoutReset').then(() => {
|
||||||
this.$router.push('/login').catch(() => {
|
this.$router.push('/login').catch(() => {
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -26,6 +26,11 @@ export default new Vuex.Store({
|
|||||||
},
|
},
|
||||||
closePlayer(state) {
|
closePlayer(state) {
|
||||||
state.playerActive = false;
|
state.playerActive = false;
|
||||||
|
},
|
||||||
|
logoutReset(state) {
|
||||||
|
state.userdata.name = null;
|
||||||
|
state.playerUrl = "";
|
||||||
|
state.playerActive = false;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
actions: {
|
actions: {
|
||||||
@ -40,6 +45,9 @@ export default new Vuex.Store({
|
|||||||
},
|
},
|
||||||
closePlayer({commit}) {
|
closePlayer({commit}) {
|
||||||
commit('closePlayer');
|
commit('closePlayer');
|
||||||
|
},
|
||||||
|
logoutReset({commit}) {
|
||||||
|
commit('logoutReset');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
modules: {},
|
modules: {},
|
||||||
|
Loading…
Reference in New Issue
Block a user