We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
user
1 parent 709358a commit 05d778bCopy full SHA for 05d778b
src/use-auth/use-auth.ts
@@ -48,10 +48,10 @@ export function useAuth<d = AuthenticateData>(options: UseAuthOptions) {
48
// user
49
const userId = ref<NullableId>(null)
50
const user = computed(() => {
51
- if (!entityService)
+ if (!entityService || !userId.value)
52
return null
53
- const u = entityService?.getFromStore(userId)
54
- return u.value || null
+ const u = entityService?.store.itemsById[userId.value]
+ return u || null
55
})
56
57
// error
0 commit comments