1
0
Fork 0
mirror of https://gitlab.com/bramw/baserow.git synced 2025-04-13 00:38:06 +00:00
bramw_baserow/web-frontend/plugins/auth.js
2019-06-21 20:22:57 +02:00

11 lines
235 B
JavaScript

export default function({ store }) {
if (!process.browser) {
return
}
const user = JSON.parse(localStorage.getItem('user'))
if (user) {
store.commit('auth/SET_USER_DATA', user)
store.dispatch('auth/refresh')
}
}