1
0
mirror of https://github.com/square/okhttp.git synced 2025-07-29 17:41:17 +03:00

Use vals in OkHttpClient

This commit is contained in:
Jesse Wilson
2019-05-25 10:34:25 -04:00
parent 8e96075fcd
commit 9c20f17270
10 changed files with 323 additions and 153 deletions

View File

@ -196,7 +196,7 @@ class DnsOverHttps internal constructor(builder: Builder) : Dns {
}
private fun getCacheOnlyResponse(request: Request): Response? {
if (!post && client.cache() != null) {
if (!post && client.cache != null) {
try {
val cacheRequest = request.newBuilder().cacheControl(CacheControl.FORCE_CACHE).build()