SY linting
This commit is contained in:
@@ -55,7 +55,9 @@ private class DataSaverImpl(preferences: PreferencesHelper) : DataSaver {
|
||||
imageUrl.contains(".gif", true) -> if (ignoreGif) imageUrl else getUrl(imageUrl)
|
||||
else -> getUrl(imageUrl)
|
||||
}
|
||||
} else imageUrl
|
||||
} else {
|
||||
imageUrl
|
||||
}
|
||||
}
|
||||
|
||||
private fun getUrl(imageUrl: String): String {
|
||||
|
||||
@@ -80,7 +80,9 @@ fun DomainManga.mangaType(sourceName: String? = Injekt.get<SourceManager>().get(
|
||||
fun Manga.defaultReaderType(type: MangaType = mangaType()): Int? {
|
||||
return if (type == MangaType.TYPE_MANHWA || type == MangaType.TYPE_WEBTOON) {
|
||||
ReadingModeType.WEBTOON.prefValue
|
||||
} else null
|
||||
} else {
|
||||
null
|
||||
}
|
||||
}
|
||||
|
||||
private fun isMangaTag(tag: String): Boolean {
|
||||
@@ -184,5 +186,5 @@ enum class MangaType {
|
||||
TYPE_MANHWA,
|
||||
TYPE_MANHUA,
|
||||
TYPE_COMIC,
|
||||
TYPE_WEBTOON
|
||||
TYPE_WEBTOON,
|
||||
}
|
||||
|
||||
@@ -26,5 +26,7 @@ fun Response.interceptAsHtml(block: (Document) -> Unit): Response {
|
||||
}
|
||||
|
||||
rebuiltResponse
|
||||
} else this
|
||||
} else {
|
||||
this
|
||||
}
|
||||
}
|
||||
|
||||
@@ -41,8 +41,12 @@ object SourceTagsUtil {
|
||||
TSUMINO_SOURCE_ID -> wrapTagTsumino(parsed.namespace, parsed.name.substringBefore('|').trim())
|
||||
else -> wrapTag(parsed.namespace, parsed.name.substringBefore('|').trim())
|
||||
}
|
||||
} else null
|
||||
} else null
|
||||
} else {
|
||||
null
|
||||
}
|
||||
} else {
|
||||
null
|
||||
}
|
||||
}
|
||||
|
||||
private fun wrapTag(namespace: String, tag: String) = if (tag.contains(spaceRegex)) {
|
||||
@@ -103,7 +107,8 @@ object SourceTagsUtil {
|
||||
IMAGE_SET_COLOR("#3f51b5"),
|
||||
COSPLAY_COLOR("#9c27b0"),
|
||||
ASIAN_PORN_COLOR("#9575cd"),
|
||||
MISC_COLOR("#f06292");
|
||||
MISC_COLOR("#f06292"),
|
||||
;
|
||||
|
||||
constructor(color: String) : this(Color.parseColor(color))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user