-
Notifications
You must be signed in to change notification settings - Fork 527
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
InfernalVoidScans: Switch to iken MultiSrc (#6642)
* switch to iken * public titleCache * protected * Change to Hive Scans
- Loading branch information
1 parent
53da00c
commit 2ff36b4
Showing
4 changed files
with
43 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
ext { | ||
extName = 'Infernal Void Scans' | ||
extClass = '.InfernalVoidScans' | ||
themePkg = 'mangathemesia' | ||
extName = 'Hive Scans' | ||
extClass = '.HiveScans' | ||
themePkg = 'iken' | ||
baseUrl = 'https://hivetoon.com' | ||
overrideVersionCode = 10 | ||
overrideVersionCode = 36 | ||
} | ||
|
||
apply from: "$rootDir/common.gradle" |
38 changes: 38 additions & 0 deletions
38
src/en/infernalvoidscans/src/eu/kanade/tachiyomi/extension/en/infernalvoidscans/HiveScans.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
package eu.kanade.tachiyomi.extension.en.infernalvoidscans | ||
|
||
import eu.kanade.tachiyomi.multisrc.iken.Iken | ||
import eu.kanade.tachiyomi.source.model.MangasPage | ||
import eu.kanade.tachiyomi.util.asJsoup | ||
import okhttp3.Response | ||
|
||
class HiveScans : Iken( | ||
"Hive Scans", | ||
"en", | ||
"https://hivetoon.com", | ||
) { | ||
|
||
override val versionId = 2 | ||
|
||
override val client = super.client.newBuilder() | ||
.addInterceptor { chain -> | ||
val request = chain.request() | ||
val headers = request.headers.newBuilder() | ||
.set("Cache-Control", "max-age=0") | ||
.build() | ||
chain.proceed(request.newBuilder().headers(headers).build()) | ||
} | ||
.build() | ||
|
||
override fun headersBuilder() = super.headersBuilder() | ||
.set("Cache-Control", "max-age=0") | ||
|
||
override fun popularMangaParse(response: Response): MangasPage { | ||
val document = response.asJsoup() | ||
|
||
val entries = document.select(".group a").mapNotNull { | ||
titleCache[it.absUrl("href").substringAfter("series/")]?.toSManga() | ||
} | ||
|
||
return MangasPage(entries, false) | ||
} | ||
} |
40 changes: 0 additions & 40 deletions
40
...rnalvoidscans/src/eu/kanade/tachiyomi/extension/en/infernalvoidscans/InfernalVoidScans.kt
This file was deleted.
Oops, something went wrong.