mirror of
https://github.com/tachiyomiorg/tachiyomi.git
synced 2024-12-23 07:31:50 +01:00
Fallback batoto urls to http (a library update took ages). Kotlin update to 1.1.3
This commit is contained in:
parent
505e642691
commit
5eeb497f2b
@ -218,7 +218,7 @@ dependencies {
|
|||||||
}
|
}
|
||||||
|
|
||||||
buildscript {
|
buildscript {
|
||||||
ext.kotlin_version = '1.1.2-3'
|
ext.kotlin_version = '1.1.3'
|
||||||
repositories {
|
repositories {
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
}
|
}
|
||||||
|
@ -161,6 +161,18 @@ class Batoto : ParsedHttpSource(), LoginSource {
|
|||||||
else -> SManga.UNKNOWN
|
else -> SManga.UNKNOWN
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override fun chapterListRequest(manga: SManga): Request {
|
||||||
|
// Https is currently very slow. The replace also saves a redirection.
|
||||||
|
var newUrl = "http://bato.to" + manga.url
|
||||||
|
if ("/comic/_/comics/" !in newUrl) {
|
||||||
|
newUrl = newUrl.replace("/comic/_/", "/comic/_/comics/")
|
||||||
|
}
|
||||||
|
|
||||||
|
return super.chapterListRequest(manga).newBuilder()
|
||||||
|
.url(newUrl)
|
||||||
|
.build()
|
||||||
|
}
|
||||||
|
|
||||||
override fun chapterListParse(response: Response): List<SChapter> {
|
override fun chapterListParse(response: Response): List<SChapter> {
|
||||||
val body = response.body()!!.string()
|
val body = response.body()!!.string()
|
||||||
val matcher = staffNotice.matcher(body)
|
val matcher = staffNotice.matcher(body)
|
||||||
|
Loading…
Reference in New Issue
Block a user