Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e6bcc49e authored by Kevin Chyn's avatar Kevin Chyn
Browse files

Do not finish early if caller is SUW

Fixes: 151576034


Test: Wipe device, go past fingerprint enrollment in SUW, press
      back button. SUW should not get stuck
Change-Id: I9021946dd169acfa205e6bacc4c4581242452983
parent 4a1f5175
Loading
Loading
Loading
Loading
+7 −5
Original line number Diff line number Diff line
@@ -68,12 +68,14 @@ public class BiometricEnrollActivity extends InstrumentedActivity {

        final int result = bm.canAuthenticate(authenticators);

        if (!WizardManagerHelper.isAnySetupWizard(getIntent())) {
            if (result == BiometricManager.BIOMETRIC_SUCCESS
                    || result == BiometricManager.BIOMETRIC_ERROR_NO_HARDWARE) {
                Log.e(TAG, "Unexpected result: " + result);
                finish();
                return;
            }
        }

        if (authenticators == BiometricManager.Authenticators.DEVICE_CREDENTIAL) {
            // If only device credential was specified, ask the user to only set that up.