From fd4c4937b11a0feba7b414cb65489cebc49b5f0a Mon Sep 17 00:00:00 2001 From: Frederik Rothenberger Date: Thu, 9 Mar 2023 11:40:51 +0100 Subject: [PATCH] Make error message on missing platform auth more actionable (#1312) This changes the error message that we show on mobile if there is no platform authenticator to something more understandable. --- src/frontend/src/utils/featureDetection.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/frontend/src/utils/featureDetection.ts b/src/frontend/src/utils/featureDetection.ts index 113b8fa6ea..a0d9a47e65 100644 --- a/src/frontend/src/utils/featureDetection.ts +++ b/src/frontend/src/utils/featureDetection.ts @@ -17,9 +17,9 @@ export const checkRequiredFeatures = async ( try { return (await PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable()) ? true - : "UserVerifyingPlatformAuthenticator is not available"; + : "This device does not offer WebAuthn authentication. Please make sure you have biometrics (fingerprint / Touch ID / Face ID) enabled and try again."; } catch (error) { - return `An error occured when checking for compatibility: ${wrapError( + return `An error occurred when checking for compatibility: ${wrapError( error )}`; }