More scanlator stuff for batoto (#4398)
* scanlator stuff * Update build.gradle * Update BatoTo.kt * fix this was the only way I found to make the "unknown" work tbh. prayge
This commit is contained in:
parent
cca5e276d2
commit
cea1f3c81c
|
@ -1,7 +1,7 @@
|
||||||
ext {
|
ext {
|
||||||
extName = 'Bato.to'
|
extName = 'Bato.to'
|
||||||
extClass = '.BatoToFactory'
|
extClass = '.BatoToFactory'
|
||||||
extVersionCode = 36
|
extVersionCode = 37
|
||||||
isNsfw = true
|
isNsfw = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -384,11 +384,14 @@ open class BatoTo(
|
||||||
val chapter = SChapter.create()
|
val chapter = SChapter.create()
|
||||||
val urlElement = element.select("a.chapt")
|
val urlElement = element.select("a.chapt")
|
||||||
val group = element.select("div.extra > a:not(.ps-3)").text()
|
val group = element.select("div.extra > a:not(.ps-3)").text()
|
||||||
|
val user = element.select("div.extra > a.ps-3").text()
|
||||||
val time = element.select("div.extra > i.ps-3").text()
|
val time = element.select("div.extra > i.ps-3").text()
|
||||||
chapter.setUrlWithoutDomain(urlElement.attr("href"))
|
chapter.setUrlWithoutDomain(urlElement.attr("href"))
|
||||||
chapter.name = urlElement.text()
|
chapter.name = urlElement.text()
|
||||||
if (group != "") {
|
chapter.scanlator = when {
|
||||||
chapter.scanlator = group
|
group.isNotBlank() -> group
|
||||||
|
user.isNotBlank() -> user
|
||||||
|
else -> "Unknown"
|
||||||
}
|
}
|
||||||
if (time != "") {
|
if (time != "") {
|
||||||
chapter.date_upload = parseChapterDate(time)
|
chapter.date_upload = parseChapterDate(time)
|
||||||
|
|
Loading…
Reference in New Issue