nzoba 0e1b9d7f56
Fix date Toonily (#11784)
Co-authored-by: Carlos <2092019+CarlosEsco@users.noreply.github.com>
2022-05-09 18:13:23 -03:00

24 lines
653 B
Kotlin

package eu.kanade.tachiyomi.extension.en.toonily
import eu.kanade.tachiyomi.multisrc.madara.Madara
import java.text.SimpleDateFormat
import java.util.Locale
class Toonily : Madara(
"Toonily",
"https://toonily.com",
"en",
SimpleDateFormat("MMM d, yy", Locale.US)
) {
// The source customized the Madara theme and broke the filter.
override val filterNonMangaItems = false
override val useNewChapterEndpoint: Boolean = true
override fun parseChapterDate(date: String?): Long {
val formattedDate = if (date?.contains("UP") == true) "today" else date
return super.parseChapterDate(formattedDate)
}
}