From 80e43e5675bf55204dd4fcb1adc02f7edcd62516 Mon Sep 17 00:00:00 2001 From: Harsh Shandilya Date: Fri, 21 Aug 2020 21:48:53 +0530 Subject: Update dependencies (#1039) * build: uprev dependencies Signed-off-by: Harsh Shandilya * Address deprecation warnings Signed-off-by: Harsh Shandilya * Update autofill, appcompat and core Signed-off-by: Harsh Shandilya --- app/src/main/java/com/zeapo/pwdstore/utils/BiometricAuthenticator.kt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'app/src/main/java/com/zeapo/pwdstore/utils') diff --git a/app/src/main/java/com/zeapo/pwdstore/utils/BiometricAuthenticator.kt b/app/src/main/java/com/zeapo/pwdstore/utils/BiometricAuthenticator.kt index d29e7ac4..11db7ed0 100644 --- a/app/src/main/java/com/zeapo/pwdstore/utils/BiometricAuthenticator.kt +++ b/app/src/main/java/com/zeapo/pwdstore/utils/BiometricAuthenticator.kt @@ -63,10 +63,9 @@ object BiometricAuthenticator { val biometricPrompt = BiometricPrompt(activity, { handler.post(it) }, authCallback) val promptInfo = BiometricPrompt.PromptInfo.Builder() .setTitle(activity.getString(dialogTitleRes)) - .setDeviceCredentialAllowed(true) .build() - if (BiometricManager.from(activity).canAuthenticate() == BiometricManager.BIOMETRIC_SUCCESS || - activity.getSystemService()?.isDeviceSecure == true) { + if (BiometricManager.from(activity).canAuthenticate(BiometricManager.Authenticators.DEVICE_CREDENTIAL) + == BiometricManager.BIOMETRIC_SUCCESS || activity.getSystemService()?.isDeviceSecure == true) { biometricPrompt.authenticate(promptInfo) } else { callback(Result.HardwareUnavailableOrDisabled) -- cgit v1.2.3