Try logging in with the existing cookie.

This commit is contained in:
Roger Braun 2017-07-02 13:07:35 +02:00 committed by eal
parent 87b18da811
commit 8b4f59e1f7
3 changed files with 7 additions and 2 deletions

View file

@ -51,6 +51,9 @@ export default function createPersistedState ({
merge({}, store.state, savedState)
)
}
if (store.state.users.lastLoginName) {
store.dispatch('loginUser', {username: store.state.users.lastLoginName, password: 'xxx'})
}
loaded = true
} catch (e) {
console.log("Couldn't load state")