I'm having an issue, where on the iOS simulator when I call window.plugins.touchid.verifyFingerprint it is calling the success callback but not actually showing the Face/Touch ID prompt.
I may have misunderstood how this is meant to work on a simulator, but my understanding was that I should:
Open the "Hardware" drop down menu
Open the "Face/Touch ID" section (dependent on device)
Click "Enrolled" (so it shows a tick next to that menu item)
On calling verifyFingerprint it should show the prompt, and I should select "Matching face" or "Non-matching face" from that same menu (or the equivalent for TouchID).
Instead, assuming I have already ticked "Enrolled", it doesn't show the prompt, and calls the success callback.
I thought this may be an issue with my app, so I started a new Cordova project, installed this plugin, and tried again there, but I get the same issue.
Example code:
# Terminal
npm i -g ionic cordova
ionic start "Test app" blank --type=angular --cordova
cd test-app
ionic cordova plugin add cordova-plugin-touch-id --variable FACEID_USAGE_DESCRIPTION="For easy authentication"
# run app in iOS simulator
// Run from Safari console attached to iOS emulator
window.plugins.touchid.isAvailable(console.log, console.error);
// logs `'face'`
window.plugins.touchid.didFingerprintDatabaseChange(console.log, console.error);
// logs `false`
window.plugins.touchid.verifyFingerprint('Some message...', console.log, console.error);
// logs `null`
///////
function onSuccess() { console.log('success') }
window.plugins.touchid.verifyFingerprint('Some message...', onSuccess, console.error);
// logs `'success'`
I'm having an issue, where on the iOS simulator when I call
window.plugins.touchid.verifyFingerprint
it is calling the success callback but not actually showing the Face/Touch ID prompt.I may have misunderstood how this is meant to work on a simulator, but my understanding was that I should:
verifyFingerprint
it should show the prompt, and I should select "Matching face" or "Non-matching face" from that same menu (or the equivalent for TouchID).Instead, assuming I have already ticked "Enrolled", it doesn't show the prompt, and calls the success callback.
I thought this may be an issue with my app, so I started a new Cordova project, installed this plugin, and tried again there, but I get the same issue.
Example code: