applyEmailPolicy
Function: applyEmailPolicy()
applyEmailPolicy(
identity,policy):ResolvedIdentity
Defined in: packages/auth/src/provider.ts:56
Apply a provider email policy to a resolved identity without mutating it
Parameters
identity
ResolvedIdentity
identity asserted by the provider
policy
the provider policy, if any
Returns
ResolvedIdentity
the identity to use (a copy with emailVerified forced to false when the claim is not trusted)
Throws
EmailDomainNotAllowed when the email is missing or its domain is not allowed