delete state.token instead of setting false
This commit is contained in:
parent
8a32731e4d
commit
bd377148ad
@ -1,3 +1,5 @@
|
||||
import { delete as del } from 'vue'
|
||||
|
||||
const oauth = {
|
||||
state: {
|
||||
clientId: false,
|
||||
@ -25,7 +27,9 @@ const oauth = {
|
||||
},
|
||||
clearToken (state) {
|
||||
state.userToken = false
|
||||
state.token = false
|
||||
// state.token is userToken with older name, coming from persistent state
|
||||
// let's clear it as well, since it is being used as a fallback of state.userToken
|
||||
del(state, 'token')
|
||||
}
|
||||
},
|
||||
getters: {
|
||||
|
Loading…
Reference in New Issue
Block a user