2 Replies Latest reply on Jan 20, 2017 4:22 AM by michalv20855892

    Using "cordova-plugin-android-fingerprint-auth" plugin gives me "Cannot read property 'apply' of undefined".

    michalv20855892

      Hello,

       

      I'm using fingerprint-auth plugin in my app, the app uses Ionic framework.

      Since the last week, when I'm trying to check if the fingerprint is available, the promise gives me positive result, but right after that it gives me an error "Cannot read property 'apply' of undefined" and the authentication popup doesn't show up.

       

      The code looks like this:

       

              if(ionic.Platform.isAndroid()) {

                  $cordovaAndroidFingerprintAuth.isAvailable()

                  .then(function(result) {

                      // result.isAvailable is true on supported devices

                      if(typeof callback !== 'undefined') {

                          callback(result.isAvailable);

                      }

                  }).catch(function(error) {

                                      // but the promise catches error "Cannot read property 'apply' of undefined" right after that...

                      if(typeof callback !== 'undefined') {

                          callback(false, error);

                      }   

                  });

              }

       

      When I build the app on my local machine, it works normally and it used to work on PhoneGap Build as well, but lately something changed and it stoped working.

       

      Thank you for your support,

       

      Michal