23158ce6da
SMS OTP Autofill currently crashes for two reasons:
1. Tasks.await has a precondition of not running on the UI thread.
2. Exceptions thrown from Tasks are always wrapped into
ExecutionExceptions and need to be unwrapped before they can be
identified as ResolvableApiException.
This commit addresses both issues by making waitForSms a proper
coroutine using withContext and a custom wrapper around Task<T> that
relies on suspendCoroutine and automatically unwraps exceptions.
(cherry picked from commit
|
||
---|---|---|
.. | ||
src | ||
.gitignore | ||
build.gradle | ||
lint.xml | ||
proguard-android-optimize.txt | ||
proguard-rules.pro |