fix crash in NfcTransport.isConnected

This commit is contained in:
Vincent Breitmoser
2022-12-27 22:20:30 +01:00
parent 3ebcd6f50a
commit cdec29f5a9

View File

@@ -82,7 +82,13 @@ public class NfcTransport implements Transport {
@Override
public boolean isConnected() {
try {
return mIsoCard != null && mIsoCard.isConnected();
} catch (SecurityException e) {
// We sometimes get this here after token is disconnected:
// java.lang.SecurityException: Permission Denial: Tag ( ID: 04 17 37 B3 71 24 80 ) is out of date
return false;
}
}
/**