File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
LTHPasscodeViewController Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -353,8 +353,13 @@ - (void)_setupFingerPrint {
353353 if (!self.biometricsContext && _allowUnlockWithBiometrics && !_useFallbackPasscode) {
354354 self.biometricsContext = [[LAContext alloc ] init ];
355355
356+ LAPolicy policy = LAPolicyDeviceOwnerAuthenticationWithBiometrics;
357+ if (@available (iOS 9.0 , *)) {
358+ policy = LAPolicyDeviceOwnerAuthentication;
359+ }
360+
356361 NSError *error = nil ;
357- if ([self .biometricsContext canEvaluatePolicy: LAPolicyDeviceOwnerAuthenticationWithBiometrics error: &error]) {
362+ if ([self .biometricsContext canEvaluatePolicy: policy error: &error]) {
358363 if (error) {
359364 return ;
360365 }
@@ -370,7 +375,7 @@ - (void)_setupFingerPrint {
370375 _animatingView.hidden = YES ;
371376
372377 // Authenticate User
373- [self .biometricsContext evaluatePolicy: LAPolicyDeviceOwnerAuthenticationWithBiometrics
378+ [self .biometricsContext evaluatePolicy: policy
374379 localizedReason: LTHPasscodeViewControllerStrings (self .biometricsDetailsString)
375380 reply: ^(BOOL success, NSError *error) {
376381
You can’t perform that action at this time.
0 commit comments