mirror of
https://github.com/aniyomiorg/aniyomi.git
synced 2024-11-26 14:53:41 +03:00
Call.await(): copy exception message when preserving error stack (#9013)
This commit is contained in:
parent
589bdba0b1
commit
7559c133c0
1 changed files with 1 additions and 1 deletions
|
@ -78,7 +78,7 @@ private suspend fun Call.await(callStack: Array<StackTraceElement>): Response {
|
|||
override fun onFailure(call: Call, e: IOException) {
|
||||
// Don't bother with resuming the continuation if it is already cancelled.
|
||||
if (continuation.isCancelled) return
|
||||
val exception = IOException(e).apply { stackTrace = callStack }
|
||||
val exception = IOException(e.message, e).apply { stackTrace = callStack }
|
||||
continuation.resumeWithException(exception)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue