Client - fix language change on preferences update

This commit is contained in:
Sam 2021-10-31 19:13:31 +01:00
parent 868827fe9d
commit 1495b6796f

View File

@ -136,6 +136,11 @@ export const actions: ActionTree<IUserState, IRootState> & IUserActions = {
USER_STORE.MUTATIONS.UPDATE_AUTH_USER_PROFILE, USER_STORE.MUTATIONS.UPDATE_AUTH_USER_PROFILE,
res.data.data res.data.data
) )
context.commit(
ROOT_STORE.MUTATIONS.UPDATE_LANG,
res.data.data.language
)
locale.value = res.data.data.language
router.push('/profile/preferences') router.push('/profile/preferences')
} else { } else {
handleError(context, null) handleError(context, null)