Skip to content

Commit

Permalink
don't swallow context disposed exceptions
Browse files Browse the repository at this point in the history
  • Loading branch information
AdamVe committed Sep 11, 2024
1 parent 769aeda commit a79e2da
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions lib/exception/platform_exception_decoder.dart
Original file line number Diff line number Diff line change
Expand Up @@ -24,17 +24,11 @@ extension Decoder on PlatformException {

bool _isApduException() => code == 'ApduException';

bool _isContextDisposed() => code == 'ContextDisposedException';

Exception decode() {
if (_isCancellation()) {
return CancellationException();
}

if (_isContextDisposed()) {
return CancellationException();
}

if (message != null && _isApduException()) {
final regExp = RegExp(
r'^com.yubico.yubikit.core.smartcard.ApduException: APDU error: 0x(.*)$');
Expand Down

0 comments on commit a79e2da

Please sign in to comment.