Merge pull request #2119 from 821938089/little-fix

优化
This commit is contained in:
kunfei
2022-08-02 08:37:29 +08:00
committed by GitHub
2 changed files with 4 additions and 2 deletions

View File

@@ -159,7 +159,9 @@ class Coroutine<T>(
error?.let { dispatchCallback(this, e, it) }
}
} finally {
finally?.let { dispatchVoidCallback(this, it) }
withContext(NonCancellable) {
finally?.let { dispatchVoidCallback(this, it) }
}
}
}
}

View File

@@ -71,7 +71,7 @@ open class WebDav(val path: String, val authorization: Authorization) {
private val webDavClient by lazy {
val authInterceptor = Interceptor { chain ->
var request = chain.request()
if (request.url.host == host) {
if (request.url.host.equals(host, true)) {
request = request
.newBuilder()
.header(authorization.name, authorization.data)