mirror of
https://github.com/aniyomiorg/aniyomi.git
synced 2024-11-24 05:38:01 +03:00
Increase default connect/read timeouts
This commit is contained in:
parent
305ee3c12e
commit
1d51b06d3e
1 changed files with 3 additions and 0 deletions
|
@ -2,6 +2,7 @@ package eu.kanade.tachiyomi.network
|
|||
|
||||
import android.content.Context
|
||||
import java.io.File
|
||||
import java.util.concurrent.TimeUnit
|
||||
import okhttp3.Cache
|
||||
import okhttp3.OkHttpClient
|
||||
|
||||
|
@ -16,6 +17,8 @@ class NetworkHelper(context: Context) {
|
|||
val client = OkHttpClient.Builder()
|
||||
.cookieJar(cookieManager)
|
||||
.cache(Cache(cacheDir, cacheSize))
|
||||
.connectTimeout(30, TimeUnit.SECONDS)
|
||||
.readTimeout(30, TimeUnit.SECONDS)
|
||||
.build()
|
||||
|
||||
val cloudflareClient = client.newBuilder()
|
||||
|
|
Loading…
Reference in a new issue