Don't unnecessarily wrap IOExceptions in UncaughtExceptionInterceptor

This commit is contained in:
arkon 2023-03-28 18:16:26 -04:00
parent be54b8862e
commit 1814b3b22c

View File

@ -18,7 +18,11 @@ class UncaughtExceptionInterceptor : Interceptor {
return try { return try {
chain.proceed(chain.request()) chain.proceed(chain.request())
} catch (e: Exception) { } catch (e: Exception) {
if (e is IOException) {
throw e
} else {
throw IOException(e) throw IOException(e)
} }
} }
}
} }