diff --git a/src/composables/useState.js b/src/composables/useState.js index e671d41bd..9b9c9d642 100644 --- a/src/composables/useState.js +++ b/src/composables/useState.js @@ -20,28 +20,12 @@ const headerMounted = ref(false); export function useState() { function getUser() { return computed(() => { - return { - id: user.value.id, - name: user.value.name, - nickname: user.value.nickname, - lang: user.value.lang, - darkMode: user.value.darkMode, - companyFk: user.value.companyFk, - warehouseFk: user.value.warehouseFk, - }; + return user.value; }); } function setUser(data) { - user.value = { - id: data.id, - name: data.name, - nickname: data.nickname, - lang: data.lang, - darkMode: data.darkMode, - companyFk: data.companyFk, - warehouseFk: data.warehouseFk, - }; + user.value = data; } function getRoles() {