diff --git a/multisrc/overrides/fmreader/manhwa18/src/Manhwa18.kt b/multisrc/overrides/fmreader/manhwa18/src/Manhwa18.kt index 3001a7cff..132321e54 100644 --- a/multisrc/overrides/fmreader/manhwa18/src/Manhwa18.kt +++ b/multisrc/overrides/fmreader/manhwa18/src/Manhwa18.kt @@ -50,8 +50,8 @@ class Manhwa18 : FMReader("Manhwa18", "https://manhwa18.com", "en") { info.select(".info-name:contains(Other name:) + .info-value") .firstOrNull()?.text()?.let { val altName = removeGenericWords(it) - description = when (title.toLowerCase(Locale.US)) { - altName.toLowerCase(Locale.US) -> description + description = when (title.lowercase(Locale.US)) { + altName.lowercase(Locale.US) -> description else -> description + "\n\n$altName" } } @@ -64,7 +64,7 @@ class Manhwa18 : FMReader("Manhwa18", "https://manhwa18.com", "en") { private fun removeGenericWords(name: String): String { val excludeList = listOf("manhwa", "engsub") return name.split(' ').filterNot { word -> - word.toLowerCase(Locale.US) in excludeList + word.lowercase(Locale.US) in excludeList }.joinToString(" ") } diff --git a/multisrc/overrides/foolslide/lecercleduscan/src/LeCercleDuScan.kt b/multisrc/overrides/foolslide/lecercleduscan/src/LeCercleDuScan.kt index 71326c540..77f42101b 100644 --- a/multisrc/overrides/foolslide/lecercleduscan/src/LeCercleDuScan.kt +++ b/multisrc/overrides/foolslide/lecercleduscan/src/LeCercleDuScan.kt @@ -5,7 +5,7 @@ import java.util.Locale class LeCercleDuScan : FoolSlide("Le Cercle du Scan", "https://lel.lecercleduscan.com", "fr") { override fun parseChapterDate(date: String) = super.parseChapterDate( - when (val lcDate = date.toLowerCase(Locale.FRENCH)) { + when (val lcDate = date.lowercase(Locale.FRENCH)) { "hier" -> "yesterday" "aujourd'hui" -> "today" "demain" -> "tomorrow" diff --git a/multisrc/overrides/madara/mangasorigines/src/MangasOrigines.kt b/multisrc/overrides/madara/mangasorigines/src/MangasOrigines.kt index 427c3b363..5fc9c4062 100644 --- a/multisrc/overrides/madara/mangasorigines/src/MangasOrigines.kt +++ b/multisrc/overrides/madara/mangasorigines/src/MangasOrigines.kt @@ -56,20 +56,20 @@ class MangasOrigines : Madara("Mangas Origines", "https://mangas-origines.fr", " } } val genres = select("div.genres-content a") - .map { element -> element.text().toLowerCase(Locale.ROOT) } + .map { element -> element.text().lowercase(Locale.ROOT) } .toMutableSet() // add tag(s) to genre select("div.tags-content a").forEach { element -> if (genres.contains(element.text()).not()) { - genres.add(element.text().toLowerCase(Locale.ROOT)) + genres.add(element.text().lowercase(Locale.ROOT)) } } // add manga/manhwa/manhua thinggy to genre document.select(seriesTypeSelector).firstOrNull()?.ownText()?.let { if (it.isEmpty().not() && it.notUpdating() && it != "-" && genres.contains(it).not()) { - genres.add(it.toLowerCase(Locale.ROOT)) + genres.add(it.lowercase(Locale.ROOT)) } } diff --git a/multisrc/overrides/madara/manhwanelo/src/ManhwaNelo.kt b/multisrc/overrides/madara/manhwanelo/src/ManhwaNelo.kt index 52e6a702f..c1687b965 100644 --- a/multisrc/overrides/madara/manhwanelo/src/ManhwaNelo.kt +++ b/multisrc/overrides/madara/manhwanelo/src/ManhwaNelo.kt @@ -59,7 +59,7 @@ class ManhwaNelo : Madara("ManhwaNelo", "https://manhwanelo.com", "en") { } } manga.genre = select("div.genres a") - .joinToString(", ") { element -> element.text().toLowerCase(Locale.ROOT) } + .joinToString(", ") { element -> element.text().lowercase(Locale.ROOT) } return manga } diff --git a/multisrc/overrides/madara/midnightmessscans/src/MidnightMessScans.kt b/multisrc/overrides/madara/midnightmessscans/src/MidnightMessScans.kt index caf2893d4..ed234ca2e 100644 --- a/multisrc/overrides/madara/midnightmessscans/src/MidnightMessScans.kt +++ b/multisrc/overrides/madara/midnightmessscans/src/MidnightMessScans.kt @@ -37,20 +37,20 @@ class MidnightMessScans : Madara("Midnight Mess Scans", "https://midnightmess.or } } val genres = select("div.genres-content a") - .map { element -> element.text().toLowerCase(Locale.ROOT) } + .map { element -> element.text().lowercase(Locale.ROOT) } .toMutableSet() // add tag(s) to genre select("div.tags-content a").forEach { element -> if (genres.contains(element.text()).not()) { - genres.add(element.text().toLowerCase(Locale.ROOT)) + genres.add(element.text().lowercase(Locale.ROOT)) } } // add manga/manhwa/manhua thinggy to genre document.select(seriesTypeSelector).firstOrNull()?.ownText()?.let { if (it.isEmpty().not() && it.notUpdating() && it != "-" && genres.contains(it).not()) { - genres.add(it.toLowerCase(Locale.ROOT)) + genres.add(it.lowercase(Locale.ROOT)) } } diff --git a/multisrc/overrides/mmrcms/animaregia/src/AnimaRegia.kt b/multisrc/overrides/mmrcms/animaregia/src/AnimaRegia.kt index 9fd0ceb5c..cab24d9cc 100644 --- a/multisrc/overrides/mmrcms/animaregia/src/AnimaRegia.kt +++ b/multisrc/overrides/mmrcms/animaregia/src/AnimaRegia.kt @@ -66,7 +66,7 @@ class AnimaRegia : MMRCMS("AnimaRegia", "https://animaregia.net", "pt-BR") { description = document.select("div.row div.well p").text().trim() for (element in document.select("div.col-sm-5 ul.list-group li.list-group-item")) { - when (element.text().trim().toLowerCase(BRAZILIAN_LOCALE).substringBefore(":")) { + when (element.text().trim().lowercase(BRAZILIAN_LOCALE).substringBefore(":")) { "autor(es)" -> author = element.select("a") .joinToString(", ") { it.text().trim() } "artist(s)" -> artist = element.select("a") diff --git a/multisrc/overrides/wpmangastream/asurascans/src/AsuraScansFactory.kt b/multisrc/overrides/wpmangastream/asurascans/src/AsuraScansFactory.kt index a380d8dfb..fca11f4fc 100644 --- a/multisrc/overrides/wpmangastream/asurascans/src/AsuraScansFactory.kt +++ b/multisrc/overrides/wpmangastream/asurascans/src/AsuraScansFactory.kt @@ -44,13 +44,13 @@ class AsuraScansTr : AsuraScans("https://tr.asurascans.com", "tr", SimpleDateFor thumbnail_url = infoElement.select("div.thumb img").imgAttr() val genres = infoElement.select(".mgen a") - .map { element -> element.text().toLowerCase(Locale.ROOT) } + .map { element -> element.text().lowercase(Locale.ROOT) } .toMutableSet() // add series type(manga/manhwa/manhua/other) thinggy to genre document.select(seriesTypeSelector).firstOrNull()?.ownText()?.let { if (it.isEmpty().not() && genres.contains(it).not()) { - genres.add(it.toLowerCase(Locale.ROOT)) + genres.add(it.lowercase(Locale.ROOT)) } } diff --git a/multisrc/overrides/wpmangastream/mangaswat/src/MangaSwat.kt b/multisrc/overrides/wpmangastream/mangaswat/src/MangaSwat.kt index ba753e2cf..1da0884d3 100644 --- a/multisrc/overrides/wpmangastream/mangaswat/src/MangaSwat.kt +++ b/multisrc/overrides/wpmangastream/mangaswat/src/MangaSwat.kt @@ -38,13 +38,13 @@ class MangaSwat : WPMangaStream("MangaSwat", "https://swatmanga.co", "ar", Simpl thumbnail_url = infoElement.select("img").imgAttr() val genres = infoElement.select("span:contains(التصنيف) a, .mgen a") - .map { element -> element.text().toLowerCase() } + .map { element -> element.text().lowercase() } .toMutableSet() // add series type(manga/manhwa/manhua/other) thinggy to genre document.select(seriesTypeSelector).firstOrNull()?.ownText()?.let { if (it.isEmpty().not() && genres.contains(it).not()) { - genres.add(it.toLowerCase()) + genres.add(it.lowercase()) } } diff --git a/multisrc/overrides/wpmangastream/mihentai/src/Mihentai.kt b/multisrc/overrides/wpmangastream/mihentai/src/Mihentai.kt index 1eeaba59b..2aec935c2 100644 --- a/multisrc/overrides/wpmangastream/mihentai/src/Mihentai.kt +++ b/multisrc/overrides/wpmangastream/mihentai/src/Mihentai.kt @@ -50,13 +50,13 @@ class Mihentai : WPMangaStream("Mihentai", "https://mihentai.com", "en") { thumbnail_url = infoElement.select("div.thumb img").imgAttr() val genres = infoElement.select("span:contains(Tag) a") - .map { element -> element.text().toLowerCase(Locale.ROOT) } + .map { element -> element.text().lowercase(Locale.ROOT) } .toMutableSet() // add series type(manga/manhwa/manhua/other) thinggy to genre document.select("span:contains(Type)").firstOrNull()?.ownText()?.let { if (it.isEmpty().not() && genres.contains(it).not()) { - genres.add(it.toLowerCase(Locale.ROOT)) + genres.add(it.lowercase(Locale.ROOT)) } } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/foolslide/FoolSlide.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/foolslide/FoolSlide.kt index c17f6dd97..4f2fd24ab 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/foolslide/FoolSlide.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/foolslide/FoolSlide.kt @@ -152,7 +152,7 @@ abstract class FoolSlide( } protected open fun parseChapterDate(date: String): Long? { - val lcDate = date.toLowerCase(Locale.ROOT) + val lcDate = date.lowercase(Locale.ROOT) if (lcDate.endsWith(" ago")) parseRelativeDate(lcDate)?.let { return it } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewer.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewer.kt index 336052459..f3d027d66 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewer.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewer.kt @@ -50,7 +50,7 @@ abstract class GigaViewer( protected val dayOfWeek: String by lazy { Calendar.getInstance() .getDisplayName(Calendar.DAY_OF_WEEK, Calendar.LONG, Locale.US)!! - .toLowerCase(Locale.US) + .lowercase(Locale.US) } protected open val publisher: String = "" diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/Madara.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/Madara.kt index 44a8db449..680cd8946 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/Madara.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/Madara.kt @@ -652,14 +652,14 @@ abstract class Madara( } } val genres = select(mangaDetailsSelectorGenre) - .map { element -> element.text().toLowerCase(Locale.ROOT) } + .map { element -> element.text().lowercase(Locale.ROOT) } .toMutableSet() // add tag(s) to genre if (mangaDetailsSelectorTag.isNotEmpty()) { select(mangaDetailsSelectorTag).forEach { element -> if (genres.contains(element.text()).not()) { - genres.add(element.text().toLowerCase(Locale.ROOT)) + genres.add(element.text().lowercase(Locale.ROOT)) } } } @@ -667,7 +667,7 @@ abstract class Madara( // add manga/manhwa/manhua thinggy to genre document.select(seriesTypeSelector).firstOrNull()?.ownText()?.let { if (it.isEmpty().not() && it.notUpdating() && it != "-" && genres.contains(it).not()) { - genres.add(it.toLowerCase(Locale.ROOT)) + genres.add(it.lowercase(Locale.ROOT)) } } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madtheme/MadTheme.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madtheme/MadTheme.kt index 82f044d4e..52cf5d243 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madtheme/MadTheme.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madtheme/MadTheme.kt @@ -128,7 +128,7 @@ abstract class MadTheme( (altNames.takeIf { it.isNotEmpty() }?.let { "\n\nAlt name(s): ${it.joinToString()}" } ?: "") val statusText = document.select(".detail .meta > p > strong:contains(Status) ~ a").first()!!.text() - status = when (statusText.toLowerCase(Locale.US)) { + status = when (statusText.lowercase(Locale.US)) { "ongoing" -> SManga.ONGOING "completed" -> SManga.COMPLETED else -> SManga.UNKNOWN diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabox/MangaBox.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabox/MangaBox.kt index 68bed73d6..7b587117c 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabox/MangaBox.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabox/MangaBox.kt @@ -271,7 +271,7 @@ abstract class MangaBox( // Based on change_alias JS function from Mangakakalot's website @SuppressLint("DefaultLocale") open fun normalizeSearchQuery(query: String): String { - var str = query.toLowerCase() + var str = query.lowercase() str = str.replace("[àáạảãâầấậẩẫăằắặẳẵ]".toRegex(), "a") str = str.replace("[èéẹẻẽêềếệểễ]".toRegex(), "e") str = str.replace("[ìíịỉĩ]".toRegex(), "i") diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainac.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainac.kt index d9097cc82..e2014432a 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainac.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainac.kt @@ -69,8 +69,8 @@ abstract class MangaMainac( private fun substringextract(text: String, start: String, end: String): String = text.substringAfter(start).substringBefore(end).trim() private fun parseStatus(element: String): Int = when { - element.toLowerCase().contains("ongoing (pub") -> SManga.ONGOING - element.toLowerCase().contains("completed (pub") -> SManga.COMPLETED + element.lowercase().contains("ongoing (pub") -> SManga.ONGOING + element.lowercase().contains("completed (pub") -> SManga.COMPLETED else -> SManga.UNKNOWN } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMS.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMS.kt index 43504d260..0bd28e554 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMS.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMS.kt @@ -299,13 +299,13 @@ abstract class MMRCMS( val detailDescription = setOf("description", "resumen") for (element in document.select(".row .dl-horizontal dt")) { - when (element.text().trim().toLowerCase().removeSuffix(":")) { + when (element.text().trim().lowercase().removeSuffix(":")) { in detailAuthor -> author = element.nextElementSibling().text() in detailArtist -> artist = element.nextElementSibling().text() in detailGenre -> genre = element.nextElementSibling().select("a").joinToString { it.text().trim() } - in detailStatus -> status = when (element.nextElementSibling().text().trim().toLowerCase()) { + in detailStatus -> status = when (element.nextElementSibling().text().trim().lowercase()) { in detailStatusComplete -> SManga.COMPLETED in detailStatusOngoing -> SManga.ONGOING else -> SManga.UNKNOWN @@ -314,13 +314,13 @@ abstract class MMRCMS( } // When details are in a .panel instead of .row (ES sources) for (element in document.select("div.panel span.list-group-item")) { - when (element.select("b").text().toLowerCase().substringBefore(":")) { + when (element.select("b").text().lowercase().substringBefore(":")) { in detailAuthor -> author = element.select("b + a").text() in detailArtist -> artist = element.select("b + a").text() in detailGenre -> genre = element.getElementsByTag("a").joinToString { it.text().trim() } - in detailStatus -> status = when (element.select("b + span.label").text().toLowerCase()) { + in detailStatus -> status = when (element.select("b + span.label").text().lowercase()) { in detailStatusComplete -> SManga.COMPLETED in detailStatusOngoing -> SManga.ONGOING else -> SManga.UNKNOWN diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSSources.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSSources.kt index 3ed2f26be..590ba412d 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSSources.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSSources.kt @@ -19,7 +19,7 @@ class MMRCMSSources { val lang: String, override val isNsfw: Boolean = false, override val className: String = name.replace(" ", ""), - override val pkgName: String = className.toLowerCase(Locale.ENGLISH), + override val pkgName: String = className.lowercase(Locale.ENGLISH), override val sourceName: String = name, override val overrideVersionCode: Int = 0, ) : SourceData() @@ -30,7 +30,7 @@ class MMRCMSSources { val langs: List, override val isNsfw: Boolean = false, override val className: String = name.replace(" ", "") + "Factory", - override val pkgName: String = className.substringBefore("Factory").toLowerCase(Locale.ENGLISH), + override val pkgName: String = className.substringBefore("Factory").lowercase(Locale.ENGLISH), override val sourceName: String = name, override val overrideVersionCode: Int = 0, ) : SourceData() diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/wpmangastream/WPMangaStream.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/wpmangastream/WPMangaStream.kt index c836fa9b2..47a3d63f9 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/wpmangastream/WPMangaStream.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/wpmangastream/WPMangaStream.kt @@ -210,13 +210,13 @@ abstract class WPMangaStream( thumbnail_url = infoElement.select("div.thumb img").imgAttr() val genres = infoElement.select("span:contains(Genre) a, .mgen a") - .map { element -> element.text().toLowerCase() } + .map { element -> element.text().lowercase() } .toMutableSet() // add series type(manga/manhwa/manhua/other) thinggy to genre document.select(seriesTypeSelector).firstOrNull()?.ownText()?.let { if (it.isEmpty().not() && genres.contains(it).not()) { - genres.add(it.toLowerCase()) + genres.add(it.lowercase()) } } diff --git a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHentai.kt b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHentai.kt index eecc7a4b1..5270b69ed 100644 --- a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHentai.kt +++ b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHentai.kt @@ -206,7 +206,7 @@ abstract class EHentai( thumbnailUrl = select("#gd1 div").attr("style").nullIfBlank()?.let { it.substring(it.indexOf('(') + 1 until it.lastIndexOf(')')) } - genre = select("#gdc div").text().nullIfBlank()?.trim()?.toLowerCase() + genre = select("#gdc div").text().nullIfBlank()?.trim()?.lowercase() uploader = select("#gdn").text().nullIfBlank()?.trim() @@ -225,7 +225,7 @@ abstract class EHentai( ignore { when ( left.removeSuffix(":") - .toLowerCase() + .lowercase() ) { "posted" -> datePosted = EX_DATE_FORMAT.parse(right)?.time ?: 0 "visible" -> visible = right.nullIfBlank() diff --git a/src/all/komga/src/eu/kanade/tachiyomi/extension/all/komga/Komga.kt b/src/all/komga/src/eu/kanade/tachiyomi/extension/all/komga/Komga.kt index c496be4a2..6d9622392 100644 --- a/src/all/komga/src/eu/kanade/tachiyomi/extension/all/komga/Komga.kt +++ b/src/all/komga/src/eu/kanade/tachiyomi/extension/all/komga/Komga.kt @@ -104,7 +104,7 @@ open class Komga(suffix: String = "") : ConfigurableSource, UnmeteredSource, Htt val statusToInclude = mutableListOf() filter.state.forEach { content -> if (content.state) { - statusToInclude.add(content.name.toUpperCase(Locale.ROOT)) + statusToInclude.add(content.name.uppercase(Locale.ROOT)) } } if (statusToInclude.isNotEmpty()) { @@ -354,7 +354,7 @@ open class Komga(suffix: String = "") : ConfigurableSource, UnmeteredSource, Htt ReadFilter(), TypeSelect(), CollectionSelect(listOf(CollectionFilterEntry("None")) + collections.map { CollectionFilterEntry(it.name, it.id) }), - LibraryGroup(libraries.map { LibraryFilter(it.id, it.name) }.sortedBy { it.name.toLowerCase(Locale.ROOT) }), + LibraryGroup(libraries.map { LibraryFilter(it.id, it.name) }.sortedBy { it.name.lowercase(Locale.ROOT) }), StatusGroup(listOf("Ongoing", "Ended", "Abandoned", "Hiatus").map { StatusFilter(it) }), GenreGroup(genres.map { GenreFilter(it) }), TagGroup(tags.map { TagFilter(it) }), @@ -385,7 +385,7 @@ open class Komga(suffix: String = "") : ConfigurableSource, UnmeteredSource, Htt // keep the previous ID when lang was "en", so that preferences and manga bindings are not lost override val id by lazy { - val key = "${name.toLowerCase()}/en/$versionId" + val key = "${name.lowercase()}/en/$versionId" val bytes = MessageDigest.getInstance("MD5").digest(key.toByteArray()) (0..7).map { bytes[it].toLong() and 0xff shl 8 * (7 - it) }.reduce(Long::or) and Long.MAX_VALUE } diff --git a/src/all/luscious/src/eu/kanade/tachiyomi/extension/all/luscious/Luscious.kt b/src/all/luscious/src/eu/kanade/tachiyomi/extension/all/luscious/Luscious.kt index 1a61d1049..0d8a6c9be 100644 --- a/src/all/luscious/src/eu/kanade/tachiyomi/extension/all/luscious/Luscious.kt +++ b/src/all/luscious/src/eu/kanade/tachiyomi/extension/all/luscious/Luscious.kt @@ -151,7 +151,7 @@ abstract class Luscious( } if (tagsFilter.state.isNotEmpty()) { - val tags = "+${tagsFilter.state.toLowerCase()}".replace(" ", "_") + val tags = "+${tagsFilter.state.lowercase()}".replace(" ", "_") .replace("_,", "+").replace(",_", "+").replace(",", "+") .replace("+-", "-").replace("-_", "-").trim() add( diff --git a/src/all/mangadex/src/eu/kanade/tachiyomi/extension/all/mangadex/MangaDexHelper.kt b/src/all/mangadex/src/eu/kanade/tachiyomi/extension/all/mangadex/MangaDexHelper.kt index cd9cd1e70..883664af8 100644 --- a/src/all/mangadex/src/eu/kanade/tachiyomi/extension/all/mangadex/MangaDexHelper.kt +++ b/src/all/mangadex/src/eu/kanade/tachiyomi/extension/all/mangadex/MangaDexHelper.kt @@ -387,7 +387,7 @@ class MangaDexHelper(private val lang: String) { } fun titleToSlug(title: String) = title.trim() - .toLowerCase(Locale.US) + .lowercase(Locale.US) .replace(titleSpecialCharactersRegex, "-") .replace(trailingHyphenRegex, "") .split("-") diff --git a/src/all/mangadex/src/eu/kanade/tachiyomi/extension/all/mangadex/MangaDexInterceptors.kt b/src/all/mangadex/src/eu/kanade/tachiyomi/extension/all/mangadex/MangaDexInterceptors.kt index 4415ddf23..3dd0900fc 100644 --- a/src/all/mangadex/src/eu/kanade/tachiyomi/extension/all/mangadex/MangaDexInterceptors.kt +++ b/src/all/mangadex/src/eu/kanade/tachiyomi/extension/all/mangadex/MangaDexInterceptors.kt @@ -17,10 +17,8 @@ import uy.kohesive.injekt.injectLazy /** * Rate limit requests ignore covers though */ - private val coverRegex = Regex("""/images/.*\.jpg""") private val baseInterceptor = RateLimitInterceptor(3) - val mdRateLimitInterceptor = Interceptor { chain -> return@Interceptor when (chain.request().url.toString().contains(coverRegex)) { true -> chain.proceed(chain.request()) diff --git a/src/all/mangapark/src/eu/kanade/tachiyomi/extension/all/mangapark/MangaPark.kt b/src/all/mangapark/src/eu/kanade/tachiyomi/extension/all/mangapark/MangaPark.kt index ab7ce04fa..babaabf6b 100644 --- a/src/all/mangapark/src/eu/kanade/tachiyomi/extension/all/mangapark/MangaPark.kt +++ b/src/all/mangapark/src/eu/kanade/tachiyomi/extension/all/mangapark/MangaPark.kt @@ -186,9 +186,9 @@ open class MangaPark( private fun String?.parseStatus() = if (this == null) { SManga.UNKNOWN } else when { - this.toLowerCase(Locale.US).contains("ongoing") -> SManga.ONGOING - this.toLowerCase(Locale.US).contains("hiatus") -> SManga.ONGOING - this.toLowerCase(Locale.US).contains("completed") -> SManga.COMPLETED + this.lowercase(Locale.US).contains("ongoing") -> SManga.ONGOING + this.lowercase(Locale.US).contains("hiatus") -> SManga.ONGOING + this.lowercase(Locale.US).contains("completed") -> SManga.COMPLETED else -> SManga.UNKNOWN } diff --git a/src/all/mangatoon/src/eu/kanade/tachiyomi/extension/all/mangatoon/MangaToon.kt b/src/all/mangatoon/src/eu/kanade/tachiyomi/extension/all/mangatoon/MangaToon.kt index 15a24972d..873c0f852 100644 --- a/src/all/mangatoon/src/eu/kanade/tachiyomi/extension/all/mangatoon/MangaToon.kt +++ b/src/all/mangatoon/src/eu/kanade/tachiyomi/extension/all/mangatoon/MangaToon.kt @@ -160,7 +160,7 @@ open class MangaToon( private fun String.toNormalPosterUrl(): String = replace(POSTER_SUFFIX, "$1") - private fun String.toStatus(): Int = when (toLowerCase(locale)) { + private fun String.toStatus(): Int = when (lowercase(locale)) { in ONGOING_STATUS -> SManga.ONGOING in COMPLETED_STATUS -> SManga.COMPLETED else -> SManga.UNKNOWN diff --git a/src/all/mango/src/eu/kanade/tachiyomi/extension/all/mango/Mango.kt b/src/all/mango/src/eu/kanade/tachiyomi/extension/all/mango/Mango.kt index a5b3ac1ea..6a2bdf851 100644 --- a/src/all/mango/src/eu/kanade/tachiyomi/extension/all/mango/Mango.kt +++ b/src/all/mango/src/eu/kanade/tachiyomi/extension/all/mango/Mango.kt @@ -86,9 +86,9 @@ class Mango : ConfigurableSource, UnmeteredSource, HttpSource() { // Here the best we can do is just match manga based on their titles private fun searchMangaParse(response: Response, query: String): MangasPage { - val queryLower = query.toLowerCase() + val queryLower = query.lowercase() val mangas = popularMangaParse(response).mangas - val exactMatch = mangas.firstOrNull { it.title.toLowerCase() == queryLower } + val exactMatch = mangas.firstOrNull { it.title.lowercase() == queryLower } if (exactMatch != null) { return MangasPage(listOf(exactMatch), false) } @@ -99,13 +99,13 @@ class Mango : ConfigurableSource, UnmeteredSource, HttpSource() { // Take results that potentially start the same val results = mangas.filter { - val title = it.title.toLowerCase() + val title = it.title.lowercase() val query2 = queryLower.take(7) (title.startsWith(query2, true) || title.contains(query2, true)) - }.sortedBy { textDistance.distance(queryLower, it.title.toLowerCase()) } + }.sortedBy { textDistance.distance(queryLower, it.title.lowercase()) } // Take similar results - val results2 = mangas.map { Pair(textDistance2.distance(it.title.toLowerCase(), query), it) } + val results2 = mangas.map { Pair(textDistance2.distance(it.title.lowercase(), query), it) } .filter { it.first < 0.3 }.sortedBy { it.first }.map { it.second } val combinedResults = results.union(results2) diff --git a/src/all/myreadingmanga/src/eu/kanade/tachiyomi/extension/all/myreadingmanga/MyReadingManga.kt b/src/all/myreadingmanga/src/eu/kanade/tachiyomi/extension/all/myreadingmanga/MyReadingManga.kt index 0c959c724..bce07a4e4 100644 --- a/src/all/myreadingmanga/src/eu/kanade/tachiyomi/extension/all/myreadingmanga/MyReadingManga.kt +++ b/src/all/myreadingmanga/src/eu/kanade/tachiyomi/extension/all/myreadingmanga/MyReadingManga.kt @@ -57,7 +57,7 @@ open class MyReadingManga(override val lang: String, private val siteLang: Strin // Latest @SuppressLint("DefaultLocale") override fun latestUpdatesRequest(page: Int): Request { - return GET("$baseUrl/lang/${latestLang.toLowerCase()}" + if (page > 1) "/page/$page/" else "", headers) // Home Page - Latest Manga + return GET("$baseUrl/lang/${latestLang.lowercase()}" + if (page > 1) "/page/$page/" else "", headers) // Home Page - Latest Manga } override fun latestUpdatesNextPageSelector() = "li.pagination-next" diff --git a/src/en/buttsmithy/src/eu/kanade/tachiyomi/extension/en/buttsmithy/Buttsmithy.kt b/src/en/buttsmithy/src/eu/kanade/tachiyomi/extension/en/buttsmithy/Buttsmithy.kt index f7ac378f4..be9cf1cae 100644 --- a/src/en/buttsmithy/src/eu/kanade/tachiyomi/extension/en/buttsmithy/Buttsmithy.kt +++ b/src/en/buttsmithy/src/eu/kanade/tachiyomi/extension/en/buttsmithy/Buttsmithy.kt @@ -178,7 +178,7 @@ class Buttsmithy : HttpSource() { } private fun String.lowercase(): String { - return this.toLowerCase(Locale.getDefault()) + return this.lowercase(Locale.getDefault()) } /** diff --git a/src/en/comicastle/src/eu/kanade/tachiyomi/extension/en/comicastle/Comicastle.kt b/src/en/comicastle/src/eu/kanade/tachiyomi/extension/en/comicastle/Comicastle.kt index a83de38a2..ffef103aa 100644 --- a/src/en/comicastle/src/eu/kanade/tachiyomi/extension/en/comicastle/Comicastle.kt +++ b/src/en/comicastle/src/eu/kanade/tachiyomi/extension/en/comicastle/Comicastle.kt @@ -154,7 +154,7 @@ class Comicastle : ParsedHttpSource() { ) private open class PostFilter(name: String, val vals: Array) : Filter.Select(name, vals) { - val pathSegment = name.toLowerCase(Locale.US) + val pathSegment = name.lowercase(Locale.US) fun hasSelection(): Boolean = state != 0 fun toRequestBody(): RequestBody = createRequestBody(vals[state]) } diff --git a/src/en/graphitecomics/src/eu/kanade/tachiyomi/extension/en/graphitecomics/GraphiteComics.kt b/src/en/graphitecomics/src/eu/kanade/tachiyomi/extension/en/graphitecomics/GraphiteComics.kt index 6b789bdcb..e9aa06d0c 100644 --- a/src/en/graphitecomics/src/eu/kanade/tachiyomi/extension/en/graphitecomics/GraphiteComics.kt +++ b/src/en/graphitecomics/src/eu/kanade/tachiyomi/extension/en/graphitecomics/GraphiteComics.kt @@ -26,7 +26,6 @@ import okhttp3.RequestBody.Companion.toRequestBody import okhttp3.Response import rx.Observable import uy.kohesive.injekt.injectLazy -import java.lang.UnsupportedOperationException import java.text.SimpleDateFormat import java.util.Locale import java.util.concurrent.TimeUnit diff --git a/src/en/hbrowse/src/eu/kanade/tachiyomi/extension/en/hbrowse/HBrowse.kt b/src/en/hbrowse/src/eu/kanade/tachiyomi/extension/en/hbrowse/HBrowse.kt index b01055ecd..e74a63c89 100644 --- a/src/en/hbrowse/src/eu/kanade/tachiyomi/extension/en/hbrowse/HBrowse.kt +++ b/src/en/hbrowse/src/eu/kanade/tachiyomi/extension/en/hbrowse/HBrowse.kt @@ -205,7 +205,7 @@ class HBrowse : ParsedHttpSource(), ConfigurableSource { } private class AdvTriStateFilter(val groupName: String, name: String) : Filter.TriState(name) { - val formName = "${groupName[0].toLowerCase() + groupName.drop(1).replace(" ", "")}_$name" + val formName = "${groupName[0].lowercase() + groupName.drop(1).replace(" ", "")}_$name" fun formValue() = when { this.isIncluded() -> "y" this.isExcluded() -> "n" diff --git a/src/en/hiveworks/src/eu/kanade/tachiyomi/extension/en/hiveworks/Hiveworks.kt b/src/en/hiveworks/src/eu/kanade/tachiyomi/extension/en/hiveworks/Hiveworks.kt index 93dcbd718..de244fc0a 100644 --- a/src/en/hiveworks/src/eu/kanade/tachiyomi/extension/en/hiveworks/Hiveworks.kt +++ b/src/en/hiveworks/src/eu/kanade/tachiyomi/extension/en/hiveworks/Hiveworks.kt @@ -67,7 +67,7 @@ class Hiveworks : ParsedHttpSource() { // Latest override fun latestUpdatesRequest(page: Int): Request { - val day = SimpleDateFormat("EEEE", Locale.US).format(Date()).toLowerCase(Locale.US) + val day = SimpleDateFormat("EEEE", Locale.US).format(Date()).lowercase(Locale.US) return GET("$baseUrl/home/update-day/$day", headers) } diff --git a/src/en/killsixbilliondemons/src/eu/kanade/tachiyomi/extension/en/killsixbilliondemons/KillSixBillionDemons.kt b/src/en/killsixbilliondemons/src/eu/kanade/tachiyomi/extension/en/killsixbilliondemons/KillSixBillionDemons.kt index 2882f9717..19e45a149 100644 --- a/src/en/killsixbilliondemons/src/eu/kanade/tachiyomi/extension/en/killsixbilliondemons/KillSixBillionDemons.kt +++ b/src/en/killsixbilliondemons/src/eu/kanade/tachiyomi/extension/en/killsixbilliondemons/KillSixBillionDemons.kt @@ -101,7 +101,7 @@ class KillSixBillionDemons : HttpSource() { } private fun String.lowercase(): String { - return this.toLowerCase(Locale.ROOT) + return this.lowercase(Locale.ROOT) } /** diff --git a/src/en/mangapark/src/eu/kanade/tachiyomi/extension/en/mangapark/MangaPark.kt b/src/en/mangapark/src/eu/kanade/tachiyomi/extension/en/mangapark/MangaPark.kt index 510675bfe..f6d291749 100644 --- a/src/en/mangapark/src/eu/kanade/tachiyomi/extension/en/mangapark/MangaPark.kt +++ b/src/en/mangapark/src/eu/kanade/tachiyomi/extension/en/mangapark/MangaPark.kt @@ -96,7 +96,7 @@ class MangaPark : ConfigurableSource, ParsedHttpSource() { } document.select(".attr > tbody > tr").forEach { - when (it.getElementsByTag("th").first().text().trim().toLowerCase()) { + when (it.getElementsByTag("th").first().text().trim().lowercase()) { "author(s)" -> { author = it.getElementsByTag("a").joinToString(transform = Element::text) } @@ -107,7 +107,7 @@ class MangaPark : ConfigurableSource, ParsedHttpSource() { genre = it.getElementsByTag("a").joinToString(transform = Element::text) } "status" -> { - status = when (it.getElementsByTag("td").text().trim().toLowerCase()) { + status = when (it.getElementsByTag("td").text().trim().lowercase()) { "ongoing" -> SManga.ONGOING "completed" -> SManga.COMPLETED else -> SManga.UNKNOWN @@ -216,7 +216,7 @@ class MangaPark : ConfigurableSource, ParsedHttpSource() { @SuppressLint("DefaultLocale") private fun parseDate(date: String): Long { - val lcDate = date.toLowerCase() + val lcDate = date.lowercase() if (lcDate.endsWith("ago")) return parseRelativeDate(lcDate) // Handle 'yesterday' and 'today' diff --git a/src/en/mangapill/src/eu/kanade/tachiyomi/extension/en/mangapill/MangaPill.kt b/src/en/mangapill/src/eu/kanade/tachiyomi/extension/en/mangapill/MangaPill.kt index 835267d31..f9b9a94f3 100644 --- a/src/en/mangapill/src/eu/kanade/tachiyomi/extension/en/mangapill/MangaPill.kt +++ b/src/en/mangapill/src/eu/kanade/tachiyomi/extension/en/mangapill/MangaPill.kt @@ -69,8 +69,8 @@ class MangaPill : ParsedHttpSource() { private fun parseStatus(element: String): Int = when { - element.toLowerCase(Locale.ENGLISH).contains("publishing") -> SManga.ONGOING - element.toLowerCase(Locale.ENGLISH).contains("finished") -> SManga.COMPLETED + element.lowercase(Locale.ENGLISH).contains("publishing") -> SManga.ONGOING + element.lowercase(Locale.ENGLISH).contains("finished") -> SManga.COMPLETED else -> SManga.UNKNOWN } diff --git a/src/en/mangarawclub/src/eu/kanade/tachiyomi/extension/en/mangarawclub/MangaRawClub.kt b/src/en/mangarawclub/src/eu/kanade/tachiyomi/extension/en/mangarawclub/MangaRawClub.kt index 34d939b74..d7db30bb1 100644 --- a/src/en/mangarawclub/src/eu/kanade/tachiyomi/extension/en/mangarawclub/MangaRawClub.kt +++ b/src/en/mangarawclub/src/eu/kanade/tachiyomi/extension/en/mangarawclub/MangaRawClub.kt @@ -67,14 +67,14 @@ class MangaRawClub : ParsedHttpSource() { val manga = SManga.create() val author = document.select(".author a").first()?.attr("title")?.trim() ?: "" - if (author.toLowerCase(Locale.ROOT) != "updating") + if (author.lowercase(Locale.ROOT) != "updating") manga.author = author var description = document.select(".description").first()?.text() ?: "" description = description.substringAfter("The Summary is").trim() val otherTitle = document.select(".alternative-title").first()?.text()?.trim() ?: "" - if (otherTitle.isNotEmpty() && otherTitle.toLowerCase(Locale.ROOT) != "updating") + if (otherTitle.isNotEmpty() && otherTitle.lowercase(Locale.ROOT) != "updating") description += "\n\n$altName $otherTitle" manga.description = description.trim() diff --git a/src/en/multporn/src/eu/kanade/tachiyomi/extension/en/multporn/Multporn.kt b/src/en/multporn/src/eu/kanade/tachiyomi/extension/en/multporn/Multporn.kt index 24f07df48..66740b2aa 100644 --- a/src/en/multporn/src/eu/kanade/tachiyomi/extension/en/multporn/Multporn.kt +++ b/src/en/multporn/src/eu/kanade/tachiyomi/extension/en/multporn/Multporn.kt @@ -319,7 +319,7 @@ class Multporn : ParsedHttpSource() { get() { return state.split(",").filter { it != "" }.map { Regex("[^A-Za-z0-9]").replace(it, " ").trim() - .replace("\\s+".toRegex(), "_").toLowerCase(Locale.getDefault()) + .replace("\\s+".toRegex(), "_").lowercase(Locale.getDefault()) }.distinct() } } diff --git a/src/en/nuxscans/src/eu/kanade/tachiyomi/extension/en/nuxscans/NuxScans.kt b/src/en/nuxscans/src/eu/kanade/tachiyomi/extension/en/nuxscans/NuxScans.kt index bdce0adf7..fc58e2b78 100644 --- a/src/en/nuxscans/src/eu/kanade/tachiyomi/extension/en/nuxscans/NuxScans.kt +++ b/src/en/nuxscans/src/eu/kanade/tachiyomi/extension/en/nuxscans/NuxScans.kt @@ -68,8 +68,8 @@ class NuxScans : ParsedHttpSource() { } private fun parseStatus(element: String): Int = when { - element.toLowerCase().contains("ongoing") -> SManga.ONGOING - element.toLowerCase().contains("completed") -> SManga.COMPLETED + element.lowercase().contains("ongoing") -> SManga.ONGOING + element.lowercase().contains("completed") -> SManga.COMPLETED else -> SManga.UNKNOWN } diff --git a/src/en/swordscomic/src/eu/kanade/tachiyomi/extension/en/swordscomic/SwordsComic.kt b/src/en/swordscomic/src/eu/kanade/tachiyomi/extension/en/swordscomic/SwordsComic.kt index f04307a12..e504f6a37 100644 --- a/src/en/swordscomic/src/eu/kanade/tachiyomi/extension/en/swordscomic/SwordsComic.kt +++ b/src/en/swordscomic/src/eu/kanade/tachiyomi/extension/en/swordscomic/SwordsComic.kt @@ -102,7 +102,7 @@ class SwordsComic : HttpSource() { charCount = 0 } charCount += word.length + 1 - builder.append(Uri.encode(word.toUpperCase())) + builder.append(Uri.encode(word.uppercase())) builder.append("+") } diff --git a/src/en/timelessleaf/src/eu/kanade/tachiyomi/extension/en/timelessleaf/TimelessLeaf.kt b/src/en/timelessleaf/src/eu/kanade/tachiyomi/extension/en/timelessleaf/TimelessLeaf.kt index fceccaba8..c3938a693 100644 --- a/src/en/timelessleaf/src/eu/kanade/tachiyomi/extension/en/timelessleaf/TimelessLeaf.kt +++ b/src/en/timelessleaf/src/eu/kanade/tachiyomi/extension/en/timelessleaf/TimelessLeaf.kt @@ -48,7 +48,7 @@ class TimelessLeaf : HttpSource() { // all mangas are in sub menus, go straight for that to deal with less menu items val menuLinks = document.select(".sub-menu a").filterNot { element -> - element.text().toLowerCase(Locale.ROOT).contains(pagesWeDontWant) + element.text().lowercase(Locale.ROOT).contains(pagesWeDontWant) } // combine the two lists diff --git a/src/en/voyceme/src/eu/kanade/tachiyomi/extension/en/voyceme/VoyceMe.kt b/src/en/voyceme/src/eu/kanade/tachiyomi/extension/en/voyceme/VoyceMe.kt index 6a14d3bb8..ffa8422fc 100644 --- a/src/en/voyceme/src/eu/kanade/tachiyomi/extension/en/voyceme/VoyceMe.kt +++ b/src/en/voyceme/src/eu/kanade/tachiyomi/extension/en/voyceme/VoyceMe.kt @@ -29,7 +29,6 @@ import org.jsoup.Jsoup import org.jsoup.parser.Parser import rx.Observable import uy.kohesive.injekt.injectLazy -import java.lang.Exception import java.text.ParseException import java.text.SimpleDateFormat import java.util.Locale diff --git a/src/en/zeroscans/src/eu/kanade/tachiyomi/extension/en/zeroscans/ZeroScansHelper.kt b/src/en/zeroscans/src/eu/kanade/tachiyomi/extension/en/zeroscans/ZeroScansHelper.kt index 81e0f32c4..c9d652954 100644 --- a/src/en/zeroscans/src/eu/kanade/tachiyomi/extension/en/zeroscans/ZeroScansHelper.kt +++ b/src/en/zeroscans/src/eu/kanade/tachiyomi/extension/en/zeroscans/ZeroScansHelper.kt @@ -41,7 +41,7 @@ class ZeroScansHelper { comics: List ): List { var sortedList = when (type) { - "alphabetic" -> comics.sortedBy { it.name.toLowerCase(Locale.ROOT) } + "alphabetic" -> comics.sortedBy { it.name.lowercase(Locale.ROOT) } "rating" -> comics.sortedBy { it.getRating() } "chapter_count" -> comics.sortedBy { it.chapterCount } "bookmark_count" -> comics.sortedBy { it.bookmarkCount } diff --git a/src/es/ikuhentai/src/eu/kanade/tachiyomi/extension/es/ikuhentai/Ikuhentai.kt b/src/es/ikuhentai/src/eu/kanade/tachiyomi/extension/es/ikuhentai/Ikuhentai.kt index 5c86921ea..bbceb1dcb 100755 --- a/src/es/ikuhentai/src/eu/kanade/tachiyomi/extension/es/ikuhentai/Ikuhentai.kt +++ b/src/es/ikuhentai/src/eu/kanade/tachiyomi/extension/es/ikuhentai/Ikuhentai.kt @@ -130,8 +130,8 @@ class Ikuhentai : ParsedHttpSource() { private fun parseStatus(element: String): Int = when { - element.toLowerCase().contains("ongoing") -> SManga.ONGOING - element.toLowerCase().contains("completado") -> SManga.COMPLETED + element.lowercase().contains("ongoing") -> SManga.ONGOING + element.lowercase().contains("completado") -> SManga.COMPLETED else -> SManga.UNKNOWN } diff --git a/src/es/kumanga/src/eu/kanade/tachiyomi/extension/es/kumanga/Kumanga.kt b/src/es/kumanga/src/eu/kanade/tachiyomi/extension/es/kumanga/Kumanga.kt index 3a4ea4084..0fb2bf4c9 100755 --- a/src/es/kumanga/src/eu/kanade/tachiyomi/extension/es/kumanga/Kumanga.kt +++ b/src/es/kumanga/src/eu/kanade/tachiyomi/extension/es/kumanga/Kumanga.kt @@ -78,7 +78,7 @@ class Kumanga : HttpSource() { val dt = body.select("#searchinput").attr("dt").toString() val kumangaTokenKey = encodeAndReverse(encodeAndReverse(dt)) .replace("=", "k") - .toLowerCase(Locale.ROOT) + .lowercase(Locale.ROOT) kumangaToken = body.select("div.input-group [type=hidden]").attr(kumangaTokenKey) return kumangaToken } diff --git a/src/es/mangamx/src/eu/kanade/tachiyomi/extension/es/mangamx/MangaMx.kt b/src/es/mangamx/src/eu/kanade/tachiyomi/extension/es/mangamx/MangaMx.kt index 54ff76c40..26f1a2290 100644 --- a/src/es/mangamx/src/eu/kanade/tachiyomi/extension/es/mangamx/MangaMx.kt +++ b/src/es/mangamx/src/eu/kanade/tachiyomi/extension/es/mangamx/MangaMx.kt @@ -106,7 +106,7 @@ open class MangaMx : ConfigurableSource, ParsedHttpSource() { for (filter in filters) { when (filter) { is StatusFilter -> uri.appendQueryParameter( - filter.name.toLowerCase(Locale.ROOT), + filter.name.lowercase(Locale.ROOT), statusArray[filter.state].second ) is SortBy -> { @@ -117,7 +117,7 @@ open class MangaMx : ConfigurableSource, ParsedHttpSource() { ) } is TypeFilter -> uri.appendQueryParameter( - filter.name.toLowerCase(Locale.ROOT), + filter.name.lowercase(Locale.ROOT), typedArray[filter.state].second ) is GenreFilter -> uri.appendQueryParameter( diff --git a/src/fr/furyosquad/src/eu/kanade/tachiyomi/extension/fr/furyosquad/FuryoSquad.kt b/src/fr/furyosquad/src/eu/kanade/tachiyomi/extension/fr/furyosquad/FuryoSquad.kt index 73f92dde3..63a37bc7b 100644 --- a/src/fr/furyosquad/src/eu/kanade/tachiyomi/extension/fr/furyosquad/FuryoSquad.kt +++ b/src/fr/furyosquad/src/eu/kanade/tachiyomi/extension/fr/furyosquad/FuryoSquad.kt @@ -123,7 +123,7 @@ class FuryoSquad : ParsedHttpSource() { document.select("div.comic-info").let { it.select("p.fs-comic-label").forEach { el -> - when (el.text().toLowerCase(Locale.ROOT)) { + when (el.text().lowercase(Locale.ROOT)) { "scénario" -> manga.author = el.nextElementSibling().text() "dessins" -> manga.artist = el.nextElementSibling().text() "genre" -> manga.genre = el.nextElementSibling().text() @@ -151,7 +151,7 @@ class FuryoSquad : ParsedHttpSource() { } private fun parseChapterDate(date: String): Long { - val lcDate = date.toLowerCase(Locale.ROOT) + val lcDate = date.lowercase(Locale.ROOT) if (lcDate.startsWith("il y a")) parseRelativeDate(lcDate).let { return it } diff --git a/src/fr/japscan/src/eu/kanade/tachiyomi/extension/fr/japscan/Japscan.kt b/src/fr/japscan/src/eu/kanade/tachiyomi/extension/fr/japscan/Japscan.kt index 1d5ede348..57ce0eb86 100644 --- a/src/fr/japscan/src/eu/kanade/tachiyomi/extension/fr/japscan/Japscan.kt +++ b/src/fr/japscan/src/eu/kanade/tachiyomi/extension/fr/japscan/Japscan.kt @@ -180,7 +180,7 @@ class Japscan : ConfigurableSource, ParsedHttpSource() { element.select("a").first().let { manga.setUrlWithoutDomain(it.attr("href")) manga.title = it.text() - manga.thumbnail_url = "$baseUrl/imgs/${it.attr("href").replace(Regex("/$"),".jpg").replace("manga","mangas")}".toLowerCase(Locale.ROOT) + manga.thumbnail_url = "$baseUrl/imgs/${it.attr("href").replace(Regex("/$"),".jpg").replace("manga","mangas")}".lowercase(Locale.ROOT) } return manga } @@ -356,7 +356,7 @@ class Japscan : ConfigurableSource, ParsedHttpSource() { val checkNew = ArrayList(pagecount) var maxIter = document.getElementsByTag("option").size var isSinglePage = false - if ((zjs.toLowerCase(Locale.ROOT).split("new image").size - 1) == 1) { + if ((zjs.lowercase(Locale.ROOT).split("new image").size - 1) == 1) { isSinglePage = true maxIter = 1 } diff --git a/src/fr/scantradunion/src/eu/kanade/tachiyomi/extension/fr/scantradunion/ScantradUnion.kt b/src/fr/scantradunion/src/eu/kanade/tachiyomi/extension/fr/scantradunion/ScantradUnion.kt index b43f05ca2..84d1f54f9 100644 --- a/src/fr/scantradunion/src/eu/kanade/tachiyomi/extension/fr/scantradunion/ScantradUnion.kt +++ b/src/fr/scantradunion/src/eu/kanade/tachiyomi/extension/fr/scantradunion/ScantradUnion.kt @@ -161,7 +161,7 @@ class ScantradUnion : ParsedHttpSource() { } private fun mapMangaStatusStringToConst(status: String): Int { - return when (status.trim().toLowerCase(Locale.FRENCH)) { + return when (status.trim().lowercase(Locale.FRENCH)) { "en cours" -> SManga.ONGOING "terminé" -> SManga.COMPLETED "licencié" -> SManga.LICENSED diff --git a/src/id/KomikFan/src/eu/kanade/tachiyomi/extension/id/komikfan/KomikFan.kt b/src/id/KomikFan/src/eu/kanade/tachiyomi/extension/id/komikfan/KomikFan.kt index 2f63c20a3..c1b35f137 100644 --- a/src/id/KomikFan/src/eu/kanade/tachiyomi/extension/id/komikfan/KomikFan.kt +++ b/src/id/KomikFan/src/eu/kanade/tachiyomi/extension/id/komikfan/KomikFan.kt @@ -91,8 +91,8 @@ class KomikFan : ParsedHttpSource() { } private fun parseStatus(element: String): Int = when { - element.toLowerCase().contains("ongoing") -> SManga.ONGOING - element.toLowerCase().contains("completed") -> SManga.COMPLETED + element.lowercase().contains("ongoing") -> SManga.ONGOING + element.lowercase().contains("completed") -> SManga.COMPLETED else -> SManga.UNKNOWN } diff --git a/src/id/bacakomik/src/eu/kanade/tachiyomi/extension/id/bacakomik/Bacakomik.kt b/src/id/bacakomik/src/eu/kanade/tachiyomi/extension/id/bacakomik/Bacakomik.kt index a2aaea725..9b147c618 100644 --- a/src/id/bacakomik/src/eu/kanade/tachiyomi/extension/id/bacakomik/Bacakomik.kt +++ b/src/id/bacakomik/src/eu/kanade/tachiyomi/extension/id/bacakomik/Bacakomik.kt @@ -112,8 +112,8 @@ class Bacakomik : ParsedHttpSource() { } private fun parseStatus(element: String): Int = when { - element.toLowerCase().contains("berjalan") -> SManga.ONGOING - element.toLowerCase().contains("tamat") -> SManga.COMPLETED + element.lowercase().contains("berjalan") -> SManga.ONGOING + element.lowercase().contains("tamat") -> SManga.COMPLETED else -> SManga.UNKNOWN } diff --git a/src/id/doujindesu/src/eu/kanade/tachiyomi/extension/id/doujindesu/DoujinDesu.kt b/src/id/doujindesu/src/eu/kanade/tachiyomi/extension/id/doujindesu/DoujinDesu.kt index e36a84d13..5e8e0f918 100644 --- a/src/id/doujindesu/src/eu/kanade/tachiyomi/extension/id/doujindesu/DoujinDesu.kt +++ b/src/id/doujindesu/src/eu/kanade/tachiyomi/extension/id/doujindesu/DoujinDesu.kt @@ -30,8 +30,8 @@ class DoujinDesu : ParsedHttpSource() { } private fun parseStatus(status: String) = when { - status.toLowerCase(Locale.US).contains("finished") -> SManga.ONGOING - status.toLowerCase(Locale.US).contains("publishing") -> SManga.COMPLETED + status.lowercase(Locale.US).contains("finished") -> SManga.ONGOING + status.lowercase(Locale.US).contains("publishing") -> SManga.COMPLETED else -> SManga.UNKNOWN } diff --git a/src/id/mangaku/src/eu/kanade/tachiyomi/extension/id/mangaku/Mangaku.kt b/src/id/mangaku/src/eu/kanade/tachiyomi/extension/id/mangaku/Mangaku.kt index 95a35c130..5b7a29e75 100644 --- a/src/id/mangaku/src/eu/kanade/tachiyomi/extension/id/mangaku/Mangaku.kt +++ b/src/id/mangaku/src/eu/kanade/tachiyomi/extension/id/mangaku/Mangaku.kt @@ -70,7 +70,7 @@ class Mangaku : ParsedHttpSource() { infoString.forEach { if (it.contains("")) { val info = it.split("") - val key = info[0].replace(":", "").replace("", "").trim().toLowerCase() + val key = info[0].replace(":", "").replace("", "").trim().lowercase() val value = info[1].replace(":", "").trim() when (key) { "genre" -> manga.genre = value.replace("–", ", ").replace("-", ", ").trim() @@ -163,7 +163,7 @@ class Mangaku : ParsedHttpSource() { val mangas = arrayListOf() document.select(searchMangaSelector()).forEach { element -> val manga = popularMangaFromElement(element) - if (manga.title.toLowerCase().contains(searchQuery.toLowerCase())) { + if (manga.title.lowercase().contains(searchQuery.lowercase())) { mangas.add(manga) } } diff --git a/src/id/nyanfm/src/eu/kanade/tachiyomi/extension/id/nyanfm/NyanFM.kt b/src/id/nyanfm/src/eu/kanade/tachiyomi/extension/id/nyanfm/NyanFM.kt index 16659b329..8cb55126b 100644 --- a/src/id/nyanfm/src/eu/kanade/tachiyomi/extension/id/nyanfm/NyanFM.kt +++ b/src/id/nyanfm/src/eu/kanade/tachiyomi/extension/id/nyanfm/NyanFM.kt @@ -82,8 +82,8 @@ class NyanFM : ParsedHttpSource() { } private fun parseStatus(element: String): Int = when { - element.toLowerCase().contains("ongoing") -> SManga.ONGOING - element.toLowerCase().contains("completed") -> SManga.COMPLETED + element.lowercase().contains("ongoing") -> SManga.ONGOING + element.lowercase().contains("completed") -> SManga.COMPLETED else -> SManga.UNKNOWN } diff --git a/src/it/digitalteam/src/eu/kanade/tachiyomi/extension/it/digitalteam/DigitalTeam.kt b/src/it/digitalteam/src/eu/kanade/tachiyomi/extension/it/digitalteam/DigitalTeam.kt index f029dbcf7..3df070d11 100644 --- a/src/it/digitalteam/src/eu/kanade/tachiyomi/extension/it/digitalteam/DigitalTeam.kt +++ b/src/it/digitalteam/src/eu/kanade/tachiyomi/extension/it/digitalteam/DigitalTeam.kt @@ -84,8 +84,8 @@ class DigitalTeam : ParsedHttpSource() { } private fun parseStatus(element: String): Int = when { - element.toLowerCase(Locale.ROOT).contains("in corso") -> SManga.ONGOING - element.toLowerCase(Locale.ROOT).contains("completo") -> SManga.COMPLETED + element.lowercase(Locale.ROOT).contains("in corso") -> SManga.ONGOING + element.lowercase(Locale.ROOT).contains("completo") -> SManga.COMPLETED else -> SManga.UNKNOWN } diff --git a/src/it/hentaifantasy/src/eu/kanade/tachiyomi/extension/it/hentaifantasy/HentaiFantasy.kt b/src/it/hentaifantasy/src/eu/kanade/tachiyomi/extension/it/hentaifantasy/HentaiFantasy.kt index cbc32bb92..cda544195 100644 --- a/src/it/hentaifantasy/src/eu/kanade/tachiyomi/extension/it/hentaifantasy/HentaiFantasy.kt +++ b/src/it/hentaifantasy/src/eu/kanade/tachiyomi/extension/it/hentaifantasy/HentaiFantasy.kt @@ -76,7 +76,7 @@ class HentaiFantasy : ParsedHttpSource() { filter.state .filter { it.state } .map { - paths.add(it.name.toLowerCase().replace(" ", "_")) + paths.add(it.name.lowercase().replace(" ", "_")) it.id.toString() } .forEach { tags.add(it) } diff --git a/src/it/mangaworld/src/eu/kanade/tachiyomi/extension/it/mangaworld/Mangaworld.kt b/src/it/mangaworld/src/eu/kanade/tachiyomi/extension/it/mangaworld/Mangaworld.kt index 41585c32b..db5864917 100644 --- a/src/it/mangaworld/src/eu/kanade/tachiyomi/extension/it/mangaworld/Mangaworld.kt +++ b/src/it/mangaworld/src/eu/kanade/tachiyomi/extension/it/mangaworld/Mangaworld.kt @@ -166,9 +166,8 @@ class Mangaworld : ParsedHttpSource() { } private fun parseStatus(element: String): Int = when { - - element.toLowerCase().contains("ongoing") -> SManga.ONGOING - element.toLowerCase().contains("completed") -> SManga.COMPLETED + element.lowercase().contains("ongoing") -> SManga.ONGOING + element.lowercase().contains("completed") -> SManga.COMPLETED else -> SManga.UNKNOWN } diff --git a/src/ja/senmanga/src/eu/kanade/tachiyomi/extension/ja/senmanga/SenManga.kt b/src/ja/senmanga/src/eu/kanade/tachiyomi/extension/ja/senmanga/SenManga.kt index 07643fab9..74a238b34 100644 --- a/src/ja/senmanga/src/eu/kanade/tachiyomi/extension/ja/senmanga/SenManga.kt +++ b/src/ja/senmanga/src/eu/kanade/tachiyomi/extension/ja/senmanga/SenManga.kt @@ -26,7 +26,7 @@ class SenManga : ParsedHttpSource() { override val client = super.client.newBuilder().addInterceptor { // Intercept any image requests and add a referer to them // Enables bandwidth stealing feature - val request = if (it.request().url.pathSegments.firstOrNull()?.trim()?.toLowerCase() == "viewer") { + val request = if (it.request().url.pathSegments.firstOrNull()?.trim()?.lowercase() == "viewer") { it.request().newBuilder() .addHeader( "Referer", diff --git a/src/ko/newtoki/src/eu/kanade/tachiyomi/extension/ko/newtoki/NewTokiFactory.kt b/src/ko/newtoki/src/eu/kanade/tachiyomi/extension/ko/newtoki/NewTokiFactory.kt index 2efde9c93..aaa76d0a4 100644 --- a/src/ko/newtoki/src/eu/kanade/tachiyomi/extension/ko/newtoki/NewTokiFactory.kt +++ b/src/ko/newtoki/src/eu/kanade/tachiyomi/extension/ko/newtoki/NewTokiFactory.kt @@ -173,7 +173,7 @@ class NewTokiWebtoon : NewToki("NewToki", "https://newtoki$domainNumber.com", "w } fun generateSourceId(name: String, lang: String, versionId: Int): Long { - val key = "${name.toLowerCase()}/$lang/$versionId" + val key = "${name.lowercase()}/$lang/$versionId" val bytes = MessageDigest.getInstance("MD5").digest(key.toByteArray()) return (0..7).map { bytes[it].toLong() and 0xff shl 8 * (7 - it) }.reduce(Long::or) and Long.MAX_VALUE } diff --git a/src/pt/argosscan/src/eu/kanade/tachiyomi/extension/pt/argosscan/ArgosScan.kt b/src/pt/argosscan/src/eu/kanade/tachiyomi/extension/pt/argosscan/ArgosScan.kt index 2891c14c8..d72d0af77 100644 --- a/src/pt/argosscan/src/eu/kanade/tachiyomi/extension/pt/argosscan/ArgosScan.kt +++ b/src/pt/argosscan/src/eu/kanade/tachiyomi/extension/pt/argosscan/ArgosScan.kt @@ -19,7 +19,6 @@ import eu.kanade.tachiyomi.source.online.HttpSource import kotlinx.serialization.decodeFromString import kotlinx.serialization.json.Json import kotlinx.serialization.json.JsonElement -import kotlinx.serialization.json.add import kotlinx.serialization.json.decodeFromJsonElement import kotlinx.serialization.json.jsonArray import kotlinx.serialization.json.jsonObject diff --git a/src/pt/hqnow/src/eu/kanade/tachiyomi/extension/pt/hqnow/HQNow.kt b/src/pt/hqnow/src/eu/kanade/tachiyomi/extension/pt/hqnow/HQNow.kt index 640fd08e8..d006fba40 100644 --- a/src/pt/hqnow/src/eu/kanade/tachiyomi/extension/pt/hqnow/HQNow.kt +++ b/src/pt/hqnow/src/eu/kanade/tachiyomi/extension/pt/hqnow/HQNow.kt @@ -345,7 +345,7 @@ class HQNow : HttpSource() { .replace("[^\\p{ASCII}]".toRegex(), "") .replace("[^a-zA-Z0-9\\s]+".toRegex(), "").trim() .replace("\\s+".toRegex(), "-") - .toLowerCase(Locale("pt", "BR")) + .lowercase(Locale("pt", "BR")) } private fun String.toStatus(): Int = when (this) { diff --git a/src/pt/mangavibe/src/eu/kanade/tachiyomi/extension/pt/mangavibe/MangaVibe.kt b/src/pt/mangavibe/src/eu/kanade/tachiyomi/extension/pt/mangavibe/MangaVibe.kt index 7fb749af2..73ad0515f 100644 --- a/src/pt/mangavibe/src/eu/kanade/tachiyomi/extension/pt/mangavibe/MangaVibe.kt +++ b/src/pt/mangavibe/src/eu/kanade/tachiyomi/extension/pt/mangavibe/MangaVibe.kt @@ -326,7 +326,7 @@ class MangaVibe : HttpSource() { .replace("[^\\p{ASCII}]".toRegex(), "") .replace("[^a-zA-Z0-9\\s]+".toRegex(), "").trim() .replace("\\s+".toRegex(), "-") - .toLowerCase(Locale("pt", "BR")) + .lowercase(Locale("pt", "BR")) } companion object { diff --git a/src/pt/opex/src/eu/kanade/tachiyomi/extension/pt/opex/OnePieceEx.kt b/src/pt/opex/src/eu/kanade/tachiyomi/extension/pt/opex/OnePieceEx.kt index e67893bd7..afd33db2b 100644 --- a/src/pt/opex/src/eu/kanade/tachiyomi/extension/pt/opex/OnePieceEx.kt +++ b/src/pt/opex/src/eu/kanade/tachiyomi/extension/pt/opex/OnePieceEx.kt @@ -72,7 +72,7 @@ class OnePieceEx : ParsedHttpSource() { override fun popularMangaFromElement(element: Element): SManga = SManga.create().apply { title = element.select("div.volume-nome h2").text() + " - " + element.select("div.volume-nome h3").text() - thumbnail_url = THUMBNAIL_URL_MAP[title.toUpperCase(Locale.ROOT)] ?: DEFAULT_THUMBNAIL + thumbnail_url = THUMBNAIL_URL_MAP[title.uppercase(Locale.ROOT)] ?: DEFAULT_THUMBNAIL val customUrl = "$baseUrl/mangas/".toHttpUrlOrNull()!!.newBuilder() .addQueryParameter("type", "special") @@ -142,7 +142,7 @@ class OnePieceEx : ParsedHttpSource() { val volumeEl = document.select("#post > div.volume:contains(" + title.substringAfter(" - ") + ")").first()!! author = if (title.contains("One Piece")) "Eiichiro Oda" else "OPEX" description = volumeEl.select("li.resenha").text() - thumbnail_url = THUMBNAIL_URL_MAP[title.toUpperCase(Locale.ROOT)] ?: DEFAULT_THUMBNAIL + thumbnail_url = THUMBNAIL_URL_MAP[title.uppercase(Locale.ROOT)] ?: DEFAULT_THUMBNAIL } } } diff --git a/src/ru/allhentai/src/eu/kanade/tachiyomi/extension/ru/allhentai/AllHentai.kt b/src/ru/allhentai/src/eu/kanade/tachiyomi/extension/ru/allhentai/AllHentai.kt index e2a41e009..893d46381 100644 --- a/src/ru/allhentai/src/eu/kanade/tachiyomi/extension/ru/allhentai/AllHentai.kt +++ b/src/ru/allhentai/src/eu/kanade/tachiyomi/extension/ru/allhentai/AllHentai.kt @@ -3,7 +3,6 @@ package eu.kanade.tachiyomi.extension.ru.allhentai import android.app.Application import android.content.SharedPreferences import android.widget.Toast -import androidx.preference.PreferenceScreen import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor import eu.kanade.tachiyomi.network.GET import eu.kanade.tachiyomi.network.asObservableSuccess @@ -140,7 +139,7 @@ class AllHentai : ConfigurableSource, ParsedHttpSource() { val infoElement = document.select(".expandable").first() val rawCategory = infoElement.select("span.elem_category").text() val category = if (rawCategory.isNotEmpty()) { - rawCategory.toLowerCase() + rawCategory.lowercase() } else { "манга" } diff --git a/src/ru/libhentai/src/eu/kanade/tachiyomi/extension/ru/libhentai/LibHentai.kt b/src/ru/libhentai/src/eu/kanade/tachiyomi/extension/ru/libhentai/LibHentai.kt index 5161ae808..be997b115 100644 --- a/src/ru/libhentai/src/eu/kanade/tachiyomi/extension/ru/libhentai/LibHentai.kt +++ b/src/ru/libhentai/src/eu/kanade/tachiyomi/extension/ru/libhentai/LibHentai.kt @@ -259,7 +259,7 @@ class LibHentai : ConfigurableSource, HttpSource() { when ( body.select("div.media-info-list__title:contains(Статус перевода) + div") .text() - .toLowerCase(Locale.ROOT) + .lowercase(Locale.ROOT) ) { "продолжается" -> SManga.ONGOING "завершен" -> SManga.COMPLETED diff --git a/src/ru/libmanga/src/eu/kanade/tachiyomi/extension/ru/libmanga/LibManga.kt b/src/ru/libmanga/src/eu/kanade/tachiyomi/extension/ru/libmanga/LibManga.kt index 45a39968d..9ceaf3ec1 100644 --- a/src/ru/libmanga/src/eu/kanade/tachiyomi/extension/ru/libmanga/LibManga.kt +++ b/src/ru/libmanga/src/eu/kanade/tachiyomi/extension/ru/libmanga/LibManga.kt @@ -250,7 +250,7 @@ class LibManga : ConfigurableSource, HttpSource() { when ( body.select("div.media-info-list__title:contains(Статус перевода) + div") .text() - .toLowerCase(Locale.ROOT) + .lowercase(Locale.ROOT) ) { "продолжается" -> SManga.ONGOING "завершен" -> SManga.COMPLETED diff --git a/src/ru/mangachan/src/eu/kanade/tachiyomi/extension/ru/mangachan/Mangachan.kt b/src/ru/mangachan/src/eu/kanade/tachiyomi/extension/ru/mangachan/Mangachan.kt index e609cf104..8848dca21 100644 --- a/src/ru/mangachan/src/eu/kanade/tachiyomi/extension/ru/mangachan/Mangachan.kt +++ b/src/ru/mangachan/src/eu/kanade/tachiyomi/extension/ru/mangachan/Mangachan.kt @@ -169,7 +169,7 @@ class Mangachan : ParsedHttpSource() { val imgElement = document.select("img#cover").first() val rawCategory = infoElement.select("tr:eq(1) > td:eq(1)").text() val category = if (rawCategory.isNotEmpty()) { - rawCategory.toLowerCase() + rawCategory.lowercase() } else { "манга" } diff --git a/src/ru/mangaclub/src/eu/kanade/tachiyomi/extension/ru/mangaclub/MangaClub.kt b/src/ru/mangaclub/src/eu/kanade/tachiyomi/extension/ru/mangaclub/MangaClub.kt index 59feeddfe..5aa37ca71 100644 --- a/src/ru/mangaclub/src/eu/kanade/tachiyomi/extension/ru/mangaclub/MangaClub.kt +++ b/src/ru/mangaclub/src/eu/kanade/tachiyomi/extension/ru/mangaclub/MangaClub.kt @@ -104,7 +104,7 @@ class MangaClub : ParsedHttpSource() { } description = "Читайте описание через WebView" genre = document.select("div.info a[href*=tags]").joinToString(", ") { - it.text().replaceFirstChar { it.toUpperCase() }.trim() + it.text().replaceFirstChar { it.uppercase() }.trim() } } diff --git a/src/ru/mintmanga/src/eu/kanade/tachiyomi/extension/ru/mintmanga/Mintmanga.kt b/src/ru/mintmanga/src/eu/kanade/tachiyomi/extension/ru/mintmanga/Mintmanga.kt index f94031096..c88a329d0 100644 --- a/src/ru/mintmanga/src/eu/kanade/tachiyomi/extension/ru/mintmanga/Mintmanga.kt +++ b/src/ru/mintmanga/src/eu/kanade/tachiyomi/extension/ru/mintmanga/Mintmanga.kt @@ -147,7 +147,7 @@ class Mintmanga : ConfigurableSource, ParsedHttpSource() { val infoElement = document.select(".expandable").first() val rawCategory = infoElement.select("span.elem_category").text() val category = if (rawCategory.isNotEmpty()) { - rawCategory.toLowerCase() + rawCategory.lowercase() } else { "манга" } diff --git a/src/ru/readmanga/src/eu/kanade/tachiyomi/extension/ru/readmanga/Readmanga.kt b/src/ru/readmanga/src/eu/kanade/tachiyomi/extension/ru/readmanga/Readmanga.kt index dbc1695e5..12625ea5c 100644 --- a/src/ru/readmanga/src/eu/kanade/tachiyomi/extension/ru/readmanga/Readmanga.kt +++ b/src/ru/readmanga/src/eu/kanade/tachiyomi/extension/ru/readmanga/Readmanga.kt @@ -147,7 +147,7 @@ class Readmanga : ConfigurableSource, ParsedHttpSource() { val infoElement = document.select(".expandable").first() val rawCategory = infoElement.select("span.elem_category").text() val category = if (rawCategory.isNotEmpty()) { - rawCategory.toLowerCase() + rawCategory.lowercase() } else { "манга" } diff --git a/src/ru/unicomics/src/eu/kanade/tachiyomi/extension/ru/unicomics/UniComics.kt b/src/ru/unicomics/src/eu/kanade/tachiyomi/extension/ru/unicomics/UniComics.kt index 307f238d5..0b278f478 100644 --- a/src/ru/unicomics/src/eu/kanade/tachiyomi/extension/ru/unicomics/UniComics.kt +++ b/src/ru/unicomics/src/eu/kanade/tachiyomi/extension/ru/unicomics/UniComics.kt @@ -241,7 +241,7 @@ class UniComics : ParsedHttpSource() { element.select(".list_title").first().text().let { val titleNoPrefix = it.removePrefix(manga.title).removePrefix(":").trim() chapter.name = if (titleNoPrefix.isNotEmpty()) - titleNoPrefix.replaceFirst(titleNoPrefix.first(), titleNoPrefix.first().toUpperCase()) + titleNoPrefix.replaceFirst(titleNoPrefix.first(), titleNoPrefix.first().uppercaseChar()) else "Сингл" if (titleNoPrefix.contains("№")) { diff --git a/src/ru/yaoichan/src/eu/kanade/tachiyomi/extension/ru/yaoichan/Yaoichan.kt b/src/ru/yaoichan/src/eu/kanade/tachiyomi/extension/ru/yaoichan/Yaoichan.kt index 1609f711d..22f637395 100644 --- a/src/ru/yaoichan/src/eu/kanade/tachiyomi/extension/ru/yaoichan/Yaoichan.kt +++ b/src/ru/yaoichan/src/eu/kanade/tachiyomi/extension/ru/yaoichan/Yaoichan.kt @@ -131,7 +131,7 @@ class Yaoichan : ParsedHttpSource() { val imgElement = document.select("img#cover").first() val rawCategory = infoElement.select("tr:eq(1) > td:eq(1)").text() val category = if (rawCategory.isNotEmpty()) { - rawCategory.toLowerCase() + rawCategory.lowercase() } else { "манга" } diff --git a/src/vi/iutruyentranh/src/eu/kanade/tachiyomi/extension/vi/iutruyentranh/IuTruyenTranh.kt b/src/vi/iutruyentranh/src/eu/kanade/tachiyomi/extension/vi/iutruyentranh/IuTruyenTranh.kt index fc2fddd62..96a3e5a62 100644 --- a/src/vi/iutruyentranh/src/eu/kanade/tachiyomi/extension/vi/iutruyentranh/IuTruyenTranh.kt +++ b/src/vi/iutruyentranh/src/eu/kanade/tachiyomi/extension/vi/iutruyentranh/IuTruyenTranh.kt @@ -68,8 +68,8 @@ class IuTruyenTranh : ParsedHttpSource() { is Author -> url.addQueryParameter("autart", filter.state) is GenreList -> filter.state.forEach { genre -> when (genre.state) { - Filter.TriState.STATE_INCLUDE -> genres.add(genre.name.toLowerCase()) - Filter.TriState.STATE_EXCLUDE -> genresEx.add(genre.name.toLowerCase()) + Filter.TriState.STATE_INCLUDE -> genres.add(genre.name.lowercase()) + Filter.TriState.STATE_EXCLUDE -> genresEx.add(genre.name.lowercase()) } } } diff --git a/src/zh/jinmantiantang/src/eu/kanade/tachiyomi/extension/zh/jinmantiantang/Jinmantiantang.kt b/src/zh/jinmantiantang/src/eu/kanade/tachiyomi/extension/zh/jinmantiantang/Jinmantiantang.kt index c84a153b3..4dfa921bb 100644 --- a/src/zh/jinmantiantang/src/eu/kanade/tachiyomi/extension/zh/jinmantiantang/Jinmantiantang.kt +++ b/src/zh/jinmantiantang/src/eu/kanade/tachiyomi/extension/zh/jinmantiantang/Jinmantiantang.kt @@ -51,7 +51,6 @@ class Jinmantiantang : ConfigurableSource, ParsedHttpSource() { override val client: OkHttpClient = network.cloudflareClient .newBuilder() .addNetworkInterceptor(mainSiteRateLimitInterceptor) -// .addNetworkInterceptor(RateLimitInterceptor(1, 3)) .addInterceptor(ScrambledImageInterceptor).build() // 点击量排序(人气) diff --git a/src/zh/picacomic/src/eu/kanade/tachiyomi/extension/zh/picacomic/Picacomic.kt b/src/zh/picacomic/src/eu/kanade/tachiyomi/extension/zh/picacomic/Picacomic.kt index 5a69954da..447d21bdf 100644 --- a/src/zh/picacomic/src/eu/kanade/tachiyomi/extension/zh/picacomic/Picacomic.kt +++ b/src/zh/picacomic/src/eu/kanade/tachiyomi/extension/zh/picacomic/Picacomic.kt @@ -61,7 +61,7 @@ class Picacomic : HttpSource(), ConfigurableSource { val hmacSha256Key = "~d}\$Q7\$eIni=V)9\\RK/P.RM4;9[7|@/CA}b~OW!3?EV`:<>M7pddUBL5n|0/*Cn" val apiKey = basicHeaders["api-key"] val path = url.substringAfter("$baseUrl/") - val raw = "$path$time$nonce${method}$apiKey".toLowerCase(Locale.ROOT) + val raw = "$path$time$nonce${method}$apiKey".lowercase(Locale.ROOT) return hmacSHA256(hmacSha256Key, raw).convertToString() }