IMHentai: Fix brotli issue (#18969)

* Fix brotli issue

* Rebuild
This commit is contained in:
bapeey 2023-11-14 22:07:05 -05:00 committed by GitHub
parent f9899ca41f
commit 0a597ad95c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 1 deletions

View File

@ -5,7 +5,7 @@ ext {
extName = 'IMHentai'
pkgNameSuffix = 'all.imhentai'
extClass = '.IMHentaiFactory'
extVersionCode = 12
extVersionCode = 13
isNsfw = true
}

View File

@ -31,6 +31,13 @@ class IMHentai(override val lang: String, private val imhLang: String) : ParsedH
override val client: OkHttpClient = network.cloudflareClient
.newBuilder()
.addInterceptor { chain ->
val request = chain.request()
val headers = request.headers.newBuilder()
.removeAll("Accept-Encoding")
.build()
chain.proceed(request.newBuilder().headers(headers).build())
}
.addInterceptor(
fun(chain): Response {
val response = chain.proceed(chain.request())