Updated on 2026-08-14
This commit is contained in:
parent
ba16c07dd0
commit
230ef64f37
2 changed files with 5 additions and 3 deletions
|
|
@ -74,7 +74,10 @@ class CardSession(
|
|||
}
|
||||
|
||||
runnable.run(this) { result ->
|
||||
stop()
|
||||
when (result) {
|
||||
is CompletionResult.Success -> stop()
|
||||
is CompletionResult.Failure -> stopWithError(result.error)
|
||||
}
|
||||
callback(result)
|
||||
}
|
||||
}
|
||||
|
|
@ -99,7 +102,6 @@ class CardSession(
|
|||
}
|
||||
is CompletionResult.Success -> {
|
||||
callback(this, null)
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@ abstract class Command<T : CommandResponse> : CardSessionRunnable<T> {
|
|||
}
|
||||
}
|
||||
is CompletionResult.Failure ->
|
||||
if (result.error == SessionError.TagLost()) {
|
||||
if (result.error is SessionError.TagLost) {
|
||||
session.viewDelegate.onTagLost()
|
||||
} else {
|
||||
callback(CompletionResult.Failure(result.error))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue