Skip to content
Snippets Groups Projects
Commit 2d05aef2 authored by jasper's avatar jasper
Browse files

Add await to login action'

parent 987b5162
No related branches found
No related tags found
2 merge requests!1028`master` refresh with `develop`,!709!701 Add await to login action in after_store
......@@ -241,7 +241,7 @@ const afterStoreSetup = async ({ store, i18n }) => {
// Now we have the server settings and can try logging in
if (store.state.oauth.token) {
store.dispatch('loginUser', store.state.oauth.token)
await store.dispatch('loginUser', store.state.oauth.token)
}
const router = new VueRouter({
......
......@@ -60,9 +60,6 @@ export default function createPersistedState ({
merge({}, store.state, savedState)
)
}
if (store.state.oauth.token) {
store.dispatch('loginUser', store.state.oauth.token)
}
loaded = true
} catch (e) {
console.log("Couldn't load state")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment