Closed playUruguay closed 7 years ago
Refer to https://github.com/chariotsolutions/phonegap-nfc#nfcremovendeflistener
You have to pass EXACTLY the function you passed to the addNdefListener
var listener = function(event){
vm.data.payload = $filter('decodePayload')(event.tag.ndefMessage[0]);
nfcInstance.removeNdefListener(listener);
};
nfcInstance.addNdefListener(listener )
Hi, i can read NFC tags ok, but i want to turn off the listeners to prevent repeats Here's my controller code: