From 7dff2b41da9f7404a77bcc0aae1a5e6b3ebe9aea Mon Sep 17 00:00:00 2001 From: Sebastian Villena <97059974+ruisebas@users.noreply.github.com> Date: Fri, 9 Aug 2024 11:57:33 -0400 Subject: [PATCH] fix: Returning .userCancelled when the app goes to the background during a Liveness check. --- .../FaceLiveness/Views/Liveness/FaceLivenessDetectionView.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/FaceLiveness/Views/Liveness/FaceLivenessDetectionView.swift b/Sources/FaceLiveness/Views/Liveness/FaceLivenessDetectionView.swift index ee45a9d..81eacfe 100644 --- a/Sources/FaceLiveness/Views/Liveness/FaceLivenessDetectionView.swift +++ b/Sources/FaceLiveness/Views/Liveness/FaceLivenessDetectionView.swift @@ -199,7 +199,7 @@ public struct FaceLivenessDetectorView: View { func mapError(_ livenessError: LivenessStateMachine.LivenessError) -> FaceLivenessDetectionError { switch livenessError { - case .userCancelled: + case .userCancelled, .viewResignation: return .userCancelled case .timedOut: return .faceInOvalMatchExceededTimeLimitError