naoufal / react-native-touch-id

React Native authentication with the native Touch ID popup.

Home Page:https://www.npmjs.com/package/react-native-touch-id

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

passcodeFallback related issue

vaibhav813 opened this issue · comments

in touch id when user press wrong fingerprint then popup shows enter passcode but when click on enter passcode it is not dispatch me to to passcode screen it throws an error LAErrorUserFallback even i make true passcodeFallback.my options which is used as

const optionalConfigObject = {
fallbackLabel: 'Enter Passcode',
unifiedErrors: false,
passcodeFallback: true,

  };

TouchID.authenticate(
'This is a secure area, please authenticate yourself.',
optionalConfigObject,
)
.then(success => {
// do something...
})
.catch(error => {
let errorCode = error.code;

      if (errorCode == 'LAErrorUserCancel') {
       // do something...
      } else if (errorCode == 'LAErrorPasscodeNotSet') {
       // do something...
      } else if (errorCode == 'LAErrorUserFallback') {
       // do something...
      } else if (errorCode == 'RCTTouchIDUnknownError') {
      // do something...
      } else {
        alert(error.message);
      }

      console.log('Error is ', error);
    });

@vaibhav813 any update with this? I'm having the same issue and now with face masks, this is critical.