Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
.map(type => {
switch (type) {
case LocalAuthentication.AuthenticationType.FINGERPRINT:
return 'FINGERPRINT';
case LocalAuthentication.AuthenticationType.FACIAL_RECOGNITION:
return 'FACIAL_RECOGNITION';
default:
throw new Error(`Unrecognised authentication type returned: '${type}'`);
}
})
.join(', ');