From 15f07bd2bd93850389e67597a09ab81774e169d4 Mon Sep 17 00:00:00 2001 From: Chopper <156493704+choppeh@users.noreply.github.com> Date: Wed, 15 Jan 2025 09:49:50 -0300 Subject: [PATCH] Siikomik: Fix page loading (#7174) Fix page loading --- src/id/siimanga/build.gradle | 4 +-- .../extension/id/siimanga/Siikomik.kt | 28 ++++++++----------- 2 files changed, 13 insertions(+), 19 deletions(-) diff --git a/src/id/siimanga/build.gradle b/src/id/siimanga/build.gradle index d8961caac..0f2b84338 100644 --- a/src/id/siimanga/build.gradle +++ b/src/id/siimanga/build.gradle @@ -2,8 +2,8 @@ ext { extName = 'Siikomik' extClass = '.Siikomik' themePkg = 'mangathemesia' - baseUrl = 'https://siikomik.lat' - overrideVersionCode = 10 + baseUrl = 'https://siikomik.cc' + overrideVersionCode = 11 isNsfw = false } diff --git a/src/id/siimanga/src/eu/kanade/tachiyomi/extension/id/siimanga/Siikomik.kt b/src/id/siimanga/src/eu/kanade/tachiyomi/extension/id/siimanga/Siikomik.kt index eb9d84eb1..3700218c1 100644 --- a/src/id/siimanga/src/eu/kanade/tachiyomi/extension/id/siimanga/Siikomik.kt +++ b/src/id/siimanga/src/eu/kanade/tachiyomi/extension/id/siimanga/Siikomik.kt @@ -1,29 +1,23 @@ package eu.kanade.tachiyomi.extension.id.siimanga import eu.kanade.tachiyomi.multisrc.mangathemesia.MangaThemesia -import eu.kanade.tachiyomi.network.interceptor.rateLimit -import okhttp3.internal.http.HTTP_INTERNAL_SERVER_ERROR -import okhttp3.internal.http.HTTP_OK +import eu.kanade.tachiyomi.network.GET +import eu.kanade.tachiyomi.source.model.Page +import okhttp3.Request class Siikomik : MangaThemesia( "Siikomik", - "https://siikomik.lat", + "https://siikomik.cc", "id", ) { override val versionId = 2 - override val client = super.client.newBuilder() - .rateLimit(3) - .addInterceptor { chain -> - val response = chain.proceed(chain.request()) - if (response.code == HTTP_INTERNAL_SERVER_ERROR) { - return@addInterceptor response.newBuilder() - .code(HTTP_OK) - .build() - } - response - } - .build() - override val hasProjectPage = true + + override fun imageRequest(page: Page): Request { + val imageHeaders = headers.newBuilder() + .removeAll("Referer") + .build() + return GET(page.imageUrl!!, imageHeaders) + } }