oblador / react-native-keychain

:key: Keychain Access for React Native
MIT License
3.12k stars 515 forks source link

RNKeychainManager is null, cannot read property 'getSupportedBiometryType' of null on Android Device #551

Open BranislavBrnjos opened 2 years ago

BranislavBrnjos commented 2 years ago

Hello, I have followed the installation step.

  1. Run yarn add react-native-keychain 1 a. Only for React Native <= 0.59: $ react-native link react-native-keychain and check MainApplication.java to verify the package was added. See manual installation below if you have issues with react-native link.
  2. Run pod install in ios/ directory to install iOS dependencies.
  3. If you want to support FaceID, add an NSFaceIDUsageDescription entry in your Info.plist.
  4. Re-build your Android and iOS projects.`

On iOS Everything works fine and the getSupportedBiometryType returns a string or null depending if the biometrics authentication is enabled. On android on another hand, I get a Render Error: Cannot Read property 'getSupportedBiometryType' of null.

I also did the react-native link react-native-keychain command to try to fix the issue, but i had no luck.

Packages: "react-native": "0.64.2", "react-native-keychain": "^8.1.0",

Images:

Screen Shot 2022-06-24 at 2 52 46 PM Screen Shot 2022-06-24 at 2 52 39 PM Screen Shot 2022-06-24 at 2 54 09 PM
BranislavBrnjos commented 2 years ago

Note: I also did the manual android install.

settings.gradle

Screen Shot 2022-06-25 at 8 37 05 PM

MainApplication.java

Screen Shot 2022-06-25 at 8 36 50 PM

proguard-rules.pro

Screen Shot 2022-06-25 at 8 36 45 PM

build.gradle

Screen Shot 2022-06-25 at 8 36 39 PM
TranQuyenSinh commented 7 months ago

Same error, anyone have a solution??