From b608c90b213e7a9cd28922e65f4c73c9bfe9129f Mon Sep 17 00:00:00 2001 From: Vetle Ledaal Date: Sun, 6 Aug 2023 21:18:44 +0000 Subject: [PATCH] Colored Manga: fix date, default to new chapter endpoint (#17413) --- .../madara/coloredmanga/src/ColoredManga.kt | 16 ++++++++++++++++ .../tachiyomi/multisrc/madara/MadaraGenerator.kt | 2 +- 2 files changed, 17 insertions(+), 1 deletion(-) create mode 100644 multisrc/overrides/madara/coloredmanga/src/ColoredManga.kt diff --git a/multisrc/overrides/madara/coloredmanga/src/ColoredManga.kt b/multisrc/overrides/madara/coloredmanga/src/ColoredManga.kt new file mode 100644 index 000000000..be16c5d06 --- /dev/null +++ b/multisrc/overrides/madara/coloredmanga/src/ColoredManga.kt @@ -0,0 +1,16 @@ +package eu.kanade.tachiyomi.extension.en.coloredmanga + +import eu.kanade.tachiyomi.multisrc.madara.Madara +import java.text.SimpleDateFormat +import java.util.Locale + +class ColoredManga : Madara( + "Colored Manga", + "https://coloredmanga.com", + "en", + dateFormat = SimpleDateFormat("dd-MMM", Locale.ENGLISH), +) { + override val useNewChapterEndpoint = true + + override fun searchPage(page: Int): String = if (page == 1) "" else "page/$page/" +} diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/MadaraGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/MadaraGenerator.kt index 65cc052c5..1ad8474c5 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/MadaraGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/MadaraGenerator.kt @@ -66,7 +66,7 @@ class MadaraGenerator : ThemeSourceGenerator { SingleLang("Clover Manga", "https://clover-manga.com", "tr", overrideVersionCode = 2), SingleLang("Coco Rip", "https://cocorip.net", "es"), SingleLang("Coffee Manga", "https://coffeemanga.io", "en", overrideVersionCode = 1), - SingleLang("Colored Manga", "https://coloredmanga.com", "en", overrideVersionCode = 1), + SingleLang("Colored Manga", "https://coloredmanga.com", "en", overrideVersionCode = 2), SingleLang("ComicKiba", "https://comickiba.com", "en", overrideVersionCode = 1), SingleLang("Comics Valley", "https://comicsvalley.com", "hi", isNsfw = true, overrideVersionCode = 1), SingleLang("ComicsWorld", "https://comicsworld.in", "hi"),