You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Can't parse 'requireStrongBiometrics'. Default will be used.
org.json.JSONException: Value null at 0 of type org.json.JSONObject$1 cannot be converted to JSONObject
at org.json.JSON.typeMismatch(JSON.java:101)
at org.json.JSONArray.getJSONObject(JSONArray.java:527) at de.niklasmerz.cordova.biometric.Args.getArgsObject(Args.java:45)
at de.niklasmerz.cordova.biometric.Args.getBoolean(Args.java:20)
at de.niklasmerz.cordova.biometric.Fingerprint.executeIsAvailable(Fingerprint.java:65)
at de.niklasmerz.cordova.biometric.Fingerprint.execute(Fingerprint.java:57)
at org.apache.cordova.CordovaPlugin.execute(CordovaPlugin.java:98)
at org.apache.cordova.PluginManager.exec(PluginManager.java:146)
at com.getcapacitor.MessageHandler.lambda$callCordovaPluginMethod$2(MessageHandler.java:155)
at com.getcapacitor.MessageHandler.$r8$lambda$NhJ0d2egplsDIA6X_OJM4sa5L1w(Unknown Source:0)
at com.getcapacitor.MessageHandler$$ExternalSyntheticLambda2.run(Unknown Source:10)
at android.os.Handler.handleCallback(Handler.java:958)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loopOnce(Looper.java:230)
at android.os.Looper.loop(Looper.java:319)
at android.os.HandlerThread.run(HandlerThread.java:67)`
The text was updated successfully, but these errors were encountered:
I encountered this issue too. It seems like two optional parameters (allowBackup and requireStrongBiometrics) were added to the isAvailable method of cordova-plugin-fingerprint-aio that are not handled by the @awesome-cordova-plugins/fingerprint-aio correctly.
/**
* Check if fingerprint authentication is available
*
* @returns {Promise<BIOMETRIC_TYPE>} Returns a promise with result which depends on device and os.
* iPhone X will return 'face' other Android or iOS devices will return 'finger' Android P+ will return 'biometric'
*/
@Cordova()
isAvailable(): Promise<BIOMETRIC_TYPE> {
return;
}
`
private void executeIsAvailable(JSONArray args) {
boolean requireStrongBiometrics = new Args(args).getBoolean("requireStrongBiometrics", false);
PluginError error = canAuthenticate(requireStrongBiometrics);
if (error != null) {
sendError(error);
} else if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.P){
sendSuccess("biometric");
} else {
sendSuccess("finger");
}
}
Can't parse 'requireStrongBiometrics'. Default will be used.
org.json.JSONException: Value null at 0 of type org.json.JSONObject$1 cannot be converted to JSONObject
at org.json.JSON.typeMismatch(JSON.java:101)
at org.json.JSONArray.getJSONObject(JSONArray.java:527) at de.niklasmerz.cordova.biometric.Args.getArgsObject(Args.java:45)
at de.niklasmerz.cordova.biometric.Args.getBoolean(Args.java:20)
at de.niklasmerz.cordova.biometric.Fingerprint.executeIsAvailable(Fingerprint.java:65)
at de.niklasmerz.cordova.biometric.Fingerprint.execute(Fingerprint.java:57)
at org.apache.cordova.CordovaPlugin.execute(CordovaPlugin.java:98)
at org.apache.cordova.PluginManager.exec(PluginManager.java:146)
at com.getcapacitor.MessageHandler.lambda$callCordovaPluginMethod$2(MessageHandler.java:155)
at com.getcapacitor.MessageHandler.$r8$lambda$NhJ0d2egplsDIA6X_OJM4sa5L1w(Unknown Source:0)
at com.getcapacitor.MessageHandler$$ExternalSyntheticLambda2.run(Unknown Source:10)
at android.os.Handler.handleCallback(Handler.java:958)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loopOnce(Looper.java:230)
at android.os.Looper.loop(Looper.java:319)
at android.os.HandlerThread.run(HandlerThread.java:67)`
The text was updated successfully, but these errors were encountered: