sngm: lower rate limit, tweak code (#598)

This commit is contained in:
Luqman 2024-01-25 13:03:57 +07:00 committed by Draff
parent 619bcf6002
commit a75f8b2428
2 changed files with 3 additions and 5 deletions

View File

@ -34,16 +34,14 @@ class Shinigami : Madara("Shinigami", "https://shinigamitoon.com", "id") {
.addInterceptor { chain -> .addInterceptor { chain ->
val request = chain.request() val request = chain.request()
val headers = request.headers.newBuilder().apply { val headers = request.headers.newBuilder().apply {
if (request.header("X-Requested-With")?.isBlank() == true) {
removeAll("X-Requested-With") removeAll("X-Requested-With")
}
}.build() }.build()
chain.proceed(request.newBuilder().headers(headers).build()) chain.proceed(request.newBuilder().headers(headers).build())
} }
.connectTimeout(10, TimeUnit.SECONDS) .connectTimeout(10, TimeUnit.SECONDS)
.readTimeout(30, TimeUnit.SECONDS) .readTimeout(30, TimeUnit.SECONDS)
.rateLimit(2) .rateLimit(3)
.build() .build()
override val mangaSubString = "semua-series" override val mangaSubString = "semua-series"

View File

@ -442,7 +442,7 @@ class MadaraGenerator : ThemeSourceGenerator {
SingleLang("Shayami", "https://shayami.com", "es"), SingleLang("Shayami", "https://shayami.com", "es"),
SingleLang("Shiba Manga", "https://shibamanga.com", "en"), SingleLang("Shiba Manga", "https://shibamanga.com", "en"),
SingleLang("Shield Manga", "https://shieldmanga.io", "en", overrideVersionCode = 3), SingleLang("Shield Manga", "https://shieldmanga.io", "en", overrideVersionCode = 3),
SingleLang("Shinigami", "https://shinigamitoon.com", "id", overrideVersionCode = 14), SingleLang("Shinigami", "https://shinigamitoon.com", "id", overrideVersionCode = 15),
SingleLang("Shooting Star Scans", "https://shootingstarscans.com", "en"), SingleLang("Shooting Star Scans", "https://shootingstarscans.com", "en"),
SingleLang("ShoujoHearts", "https://shoujohearts.com", "en", overrideVersionCode = 2), SingleLang("ShoujoHearts", "https://shoujohearts.com", "en", overrideVersionCode = 2),
SingleLang("Sinensis Scan", "https://sinensisscan.net", "pt-BR", pkgName = "sinensis", overrideVersionCode = 6), SingleLang("Sinensis Scan", "https://sinensisscan.net", "pt-BR", pkgName = "sinensis", overrideVersionCode = 6),