Commit d1203627 authored by Agate's avatar Agate 💬

Fixed #15: now flush localstorage cache on logout

parent 41d2e6e8
......@@ -43,8 +43,7 @@ export default {
// To log out, we just need to remove the token
logout () {
cache.remove('token')
cache.remove('username')
cache.clear()
this.user.authenticated = false
logger.default.info('Log out, goodbye!')
},
......
......@@ -20,5 +20,10 @@ export default {
remove (key) {
return localStorage.removeItem(key)
},
clear () {
localStorage.clear()
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment