Fixed saving token
This commit is contained in:
parent
78fe10094e
commit
41eaffba6d
|
@ -17,6 +17,7 @@ export default {
|
|||
})
|
||||
.then(response => {
|
||||
// Save the token to local storage for later use
|
||||
localStorage.removeItem('token') // Delete an eventually preexisting old token
|
||||
localStorage.setItem('token', response.data.token)
|
||||
|
||||
// Tell others the user is autheticated
|
||||
|
|
Loading…
Reference in New Issue