From c5e2a7c20a83d5660cc83c5d21c3e180f927dc33 Mon Sep 17 00:00:00 2001 From: tjroach Date: Fri, 22 Nov 2024 17:26:37 -0500 Subject: [PATCH] Fix auto sign in with device tracking --- .../statemachine/codegen/states/SignInState.kt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/aws-auth-cognito/src/main/java/com/amplifyframework/statemachine/codegen/states/SignInState.kt b/aws-auth-cognito/src/main/java/com/amplifyframework/statemachine/codegen/states/SignInState.kt index 35a1a9332..a4bf0527e 100644 --- a/aws-auth-cognito/src/main/java/com/amplifyframework/statemachine/codegen/states/SignInState.kt +++ b/aws-auth-cognito/src/main/java/com/amplifyframework/statemachine/codegen/states/SignInState.kt @@ -278,6 +278,10 @@ internal sealed class SignInState : State { is SignInEvent.EventType.FinalizeSignIn -> { StateResolution(SignedIn()) } + is SignInEvent.EventType.ConfirmDevice -> { + val action = signInActions.confirmDevice(signInEvent) + StateResolution(ConfirmingDevice(), listOf(action)) + } is SignInEvent.EventType.ThrowError -> StateResolution(Error(signInEvent.exception)) else -> defaultResolution