diff --git a/src/pt/ancientcomics/build.gradle b/src/pt/ancientcomics/build.gradle index 8d540fac8..2baa4c76c 100644 --- a/src/pt/ancientcomics/build.gradle +++ b/src/pt/ancientcomics/build.gradle @@ -1,9 +1,9 @@ ext { extName = 'Ancient Comics' extClass = '.AncientComics' - themePkg = 'mangathemesia' + themePkg = 'madara' baseUrl = 'https://ancientcomics.com.br' - overrideVersionCode = 1 + overrideVersionCode = 0 } apply from: "$rootDir/common.gradle" diff --git a/src/pt/ancientcomics/src/eu/kanade/tachiyomi/extension/pt/ancientcomics/AncientComics.kt b/src/pt/ancientcomics/src/eu/kanade/tachiyomi/extension/pt/ancientcomics/AncientComics.kt index 0146a36c7..1fa4a1f98 100644 --- a/src/pt/ancientcomics/src/eu/kanade/tachiyomi/extension/pt/ancientcomics/AncientComics.kt +++ b/src/pt/ancientcomics/src/eu/kanade/tachiyomi/extension/pt/ancientcomics/AncientComics.kt @@ -1,37 +1,21 @@ package eu.kanade.tachiyomi.extension.pt.ancientcomics -import eu.kanade.tachiyomi.multisrc.mangathemesia.MangaThemesia -import eu.kanade.tachiyomi.network.GET +import eu.kanade.tachiyomi.multisrc.madara.Madara import eu.kanade.tachiyomi.network.interceptor.rateLimit -import eu.kanade.tachiyomi.source.model.FilterList -import okhttp3.HttpUrl.Companion.toHttpUrl -import okhttp3.OkHttpClient -import okhttp3.Request -import okhttp3.Response import java.text.SimpleDateFormat import java.util.Locale -class AncientComics : MangaThemesia( +class AncientComics : Madara( "Ancient Comics", "https://ancientcomics.com.br", "pt-BR", - dateFormat = SimpleDateFormat("MMM dd, yyyy", Locale("pt", "BR")), + dateFormat = SimpleDateFormat("dd/MM/yyyy", Locale.ROOT), ) { - override val client: OkHttpClient = super.client.newBuilder() - .rateLimit(2) + override val versionId: Int = 2 + + override val useNewChapterEndpoint = true + + override val client = super.client.newBuilder() + .rateLimit(3) .build() - - override val hasProjectPage = true - - override fun searchMangaRequest(page: Int, query: String, filters: FilterList): Request { - if (query.isBlank()) return super.searchMangaRequest(page, query, filters) - - val url = baseUrl.toHttpUrl().newBuilder() - .addQueryParameter("s", query) - .build() - - return GET(url, headers) - } - - override fun chapterListParse(response: Response) = super.chapterListParse(response).reversed() }