[v25.1] fix crash when glide fails to load avatar in ShareShortcutHelper (#4417)
🙄 fixes #4416
This commit is contained in:
parent
056aaa7e0e
commit
c10f82ffa6
2 changed files with 22 additions and 9 deletions
|
|
@ -8,7 +8,6 @@ import com.bumptech.glide.request.target.Target
|
|||
import kotlin.coroutines.resume
|
||||
import kotlin.coroutines.resumeWithException
|
||||
import kotlinx.coroutines.suspendCancellableCoroutine
|
||||
import okio.IOException
|
||||
|
||||
/**
|
||||
* Allows waiting for a Glide request to complete without blocking a background thread.
|
||||
|
|
@ -26,7 +25,7 @@ suspend fun <R> RequestBuilder<R>.submitAsync(
|
|||
target: Target<R>,
|
||||
isFirstResource: Boolean
|
||||
): Boolean {
|
||||
continuation.resumeWithException(e ?: IOException("Image loading failed"))
|
||||
continuation.resumeWithException(e ?: GlideException("Image loading failed"))
|
||||
return false
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue