fix(auth): stabilize header session state and retry team token errors
This commit is contained in:
@@ -7,7 +7,8 @@
|
||||
export const useAuth = () => {
|
||||
const { getToken, initTokens, idToken } = useLogtoTokens()
|
||||
const me = useState<{ id?: string | null } | null>('me', () => null)
|
||||
const isAuthenticated = computed(() => !!me.value?.id)
|
||||
const logtoUser = useState<Record<string, unknown> | null>('logto-user', () => null)
|
||||
const isAuthenticated = computed(() => !!(me.value?.id || logtoUser.value))
|
||||
const loggedIn = isAuthenticated
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user