File tree Expand file tree Collapse file tree 3 files changed +6
-4
lines changed
authRecipe/components/feature/authPage Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -508,7 +508,7 @@ async function buildAndSetChildProps(
508508
509509 for ( const a of authComps ) {
510510 if ( a . type === "FULL_PAGE" ) {
511- const preloadRes = await a . preloadInfoAndRunChecks ( firstFactors , userContext ) ;
511+ const preloadRes = await a . preloadInfoAndRunChecks ( firstFactors , userContext , isSignUp ) ;
512512 // We skip setting if the auth page unmounted while we were checking
513513 // if we should show any full page comps
514514 if ( abort . aborted ) {
Original file line number Diff line number Diff line change @@ -83,9 +83,10 @@ export class WebauthnPreBuiltUI extends RecipeRouter {
8383 return [
8484 {
8585 type : "FULL_PAGE" ,
86- async preloadInfoAndRunChecks ( firstFactors ) {
86+ async preloadInfoAndRunChecks ( firstFactors , _ , isSignUp ) {
8787 return {
88- shouldDisplay : firstFactors . length === 1 && firstFactors . includes ( FactorIds . WEBAUTHN ) ,
88+ shouldDisplay :
89+ isSignUp && firstFactors . length === 1 && firstFactors . includes ( FactorIds . WEBAUTHN ) ,
8990 preloadInfo : { } ,
9091 } ;
9192 } ,
Original file line number Diff line number Diff line change @@ -437,7 +437,8 @@ export type FullPageAuthComponent<PreloadInfoType = any> = {
437437 type : "FULL_PAGE" ;
438438 preloadInfoAndRunChecks : (
439439 firstFactors : string [ ] ,
440- userContext : UserContext
440+ userContext : UserContext ,
441+ isSignUp : boolean
441442 ) => Promise < { shouldDisplay : true ; preloadInfo : PreloadInfoType } | { shouldDisplay : false } > ;
442443 component : React . FC < FullPageAuthComponentProps < PreloadInfoType > > ;
443444} ;
You can’t perform that action at this time.
0 commit comments