Skip to content

Commit 69abe75

Browse files
committed
chore: update core docs example
1 parent 0d725dc commit 69abe75

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

packages/amplify_core/doc/lib/auth.dart

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,9 @@ Future<void> _handleSignInResult(SignInResult result) async {
117117
// #docregion handle-confirm-signin-mfa-setup-selection
118118
case AuthSignInStep.continueSignInWithMfaSetupSelection:
119119
final allowedMfaTypes = result.nextStep.allowedMfaTypes!;
120+
if (allowedMfaTypes.length == 1) {
121+
return _handleMfaSetupSelection(allowedMfaTypes.first);
122+
}
120123
final selection = await _promptUserPreference(allowedMfaTypes);
121124
return _handleMfaSetupSelection(selection);
122125
// #enddocregion handle-confirm-signin-mfa-setup-selection

0 commit comments

Comments
 (0)