mirror of
https://github.com/mihonapp/mihon.git
synced 2025-11-16 14:07:28 +01:00
Address some Kotlin language warnings
This commit is contained in:
@@ -44,7 +44,7 @@ object ChapterRecognition {
|
||||
}
|
||||
|
||||
// Get chapter title with lower case
|
||||
var name = chapter.name.toLowerCase()
|
||||
var name = chapter.name.lowercase()
|
||||
|
||||
// Remove comma's from chapter.
|
||||
name = name.replace(',', '.')
|
||||
@@ -77,7 +77,7 @@ object ChapterRecognition {
|
||||
}
|
||||
|
||||
// Remove manga title from chapter title.
|
||||
val nameWithoutManga = name.replace(manga.title.toLowerCase(), "").trim()
|
||||
val nameWithoutManga = name.replace(manga.title.lowercase(), "").trim()
|
||||
|
||||
// Check if first value is number after title remove.
|
||||
if (updateChapter(withoutManga.find(nameWithoutManga), chapter)) {
|
||||
@@ -147,6 +147,6 @@ object ChapterRecognition {
|
||||
* x.a -> x.1, x.b -> x.2, etc
|
||||
*/
|
||||
private fun parseAlphaPostFix(alpha: Char): Float {
|
||||
return ("0." + (alpha.toInt() - 96).toString()).toFloat()
|
||||
return ("0." + (alpha.code - 96).toString()).toFloat()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user