naoufal / react-native-touch-id

React Native authentication with the native Touch ID popup.
https://www.npmjs.com/package/react-native-touch-id
1.47k stars 477 forks source link

TouchID not working on Iphone X and above #262

Closed jivanovic closed 4 years ago

jivanovic commented 4 years ago

Hello,

when I run my application on an iphone X or above, the function isSupported() returns an error and therefore trying to tell me that TouchID is not supported on this device.

Although on other iphones it seems to work just fine.

Is anyone else having this issue or maybe knows how to slove it? Any help would be appreciated :)

andrewJA commented 4 years ago

What's about permission? Did you grant access? FaceID need it unlike TouchID Also add strings in Info.plist <key>NSFaceIDUsageDescription</key> <string>To login with FaceID</string>

jivanovic commented 4 years ago

Upps, i fixed it the very same day and forgot to close the issue...My bad 💃 For anyone who is wondering what stupid thing i forgot,

SOLUTION: On ipones X and up, the function returns the string "FaceID" and not "TouchID" and ofcourse i forgot to check that option...