Review
This commit is contained in:
@@ -30,6 +30,9 @@ export function useAccountEmailState() {
|
||||
*/
|
||||
useQuery({
|
||||
enabled: !!agent.session,
|
||||
/**
|
||||
* Only refetch if the email verification s incomplete.
|
||||
*/
|
||||
refetchOnWindowFocus: !prevIsEmailVerified,
|
||||
queryKey: accountEmailStateQueryKey,
|
||||
queryFn: async () => {
|
||||
|
||||
@@ -52,18 +52,10 @@ export type Action =
|
||||
syncedAccounts: SessionAccount[]
|
||||
syncedCurrentDid: string | undefined
|
||||
}
|
||||
| {
|
||||
type: 'synced-accounts'
|
||||
syncedAccounts: SessionAccount[]
|
||||
syncedCurrentDid: string | undefined
|
||||
}
|
||||
| {
|
||||
type: 'partial-refresh-session'
|
||||
accountDid: string
|
||||
patch: Pick<
|
||||
SessionAccount,
|
||||
'emailConfirmed' | 'emailAuthFactor' | 'email'
|
||||
>
|
||||
patch: Pick<SessionAccount, 'emailConfirmed' | 'emailAuthFactor'>
|
||||
}
|
||||
|
||||
function createPublicAgentState(): AgentState {
|
||||
|
||||
Reference in New Issue
Block a user