Góc Truyện Tranh Vui: Fix warns
This commit is contained in:
2
.github/workflows/test-branch.yml
vendored
2
.github/workflows/test-branch.yml
vendored
@@ -21,7 +21,7 @@ jobs:
|
||||
- name: Set up Gradle 📦
|
||||
uses: gradle/actions/setup-gradle@017a9effdb900e5b5b2fddfb590a105619dca3c3 # v4.4.2
|
||||
with:
|
||||
cache-read-only: true
|
||||
cache-read-only: false
|
||||
|
||||
- name: Compile parsers 🚀
|
||||
run: ./gradlew compileKotlin
|
||||
|
||||
2
.github/workflows/test-parsers.yml
vendored
2
.github/workflows/test-parsers.yml
vendored
@@ -25,7 +25,7 @@ jobs:
|
||||
- name: Set up Gradle 📦
|
||||
uses: gradle/actions/setup-gradle@017a9effdb900e5b5b2fddfb590a105619dca3c3 # v4.4.2
|
||||
with:
|
||||
cache-read-only: true
|
||||
cache-read-only: false
|
||||
|
||||
- name: Compile parsers 🚀
|
||||
run: ./gradlew compileKotlin
|
||||
|
||||
@@ -7,3 +7,4 @@ org.gradle.configureondemand=true
|
||||
org.gradle.parallel=true
|
||||
org.gradle.caching=true
|
||||
org.gradle.configuration-cache=true
|
||||
org.gradle.workers.max=5
|
||||
|
||||
@@ -16,7 +16,8 @@ import org.json.JSONObject
|
||||
import java.util.*
|
||||
|
||||
@MangaSourceParser("GOCTRUYENTRANHVUI", "Góc Truyện Tranh Vui", "vi")
|
||||
internal class GocTruyenTranhVui(context: MangaLoaderContext) : PagedMangaParser(context, MangaParserSource.GOCTRUYENTRANHVUI, 50) {
|
||||
internal class GocTruyenTranhVui(context: MangaLoaderContext):
|
||||
PagedMangaParser(context, MangaParserSource.GOCTRUYENTRANHVUI, 50) {
|
||||
|
||||
override val configKeyDomain = ConfigKey.Domain("goctruyentranhvui17.com")
|
||||
private val apiUrl by lazy { "https://$domain/api/v2" }
|
||||
@@ -144,7 +145,7 @@ internal class GocTruyenTranhVui(context: MangaLoaderContext) : PagedMangaParser
|
||||
source = source
|
||||
)
|
||||
}
|
||||
} catch (e: Exception) {
|
||||
} catch (_: Exception) {
|
||||
emptyList()
|
||||
}.reversed()
|
||||
|
||||
@@ -174,9 +175,7 @@ internal class GocTruyenTranhVui(context: MangaLoaderContext) : PagedMangaParser
|
||||
|
||||
override suspend fun getPages(chapter: MangaChapter): List<MangaPage> {
|
||||
enforceRateLimit()
|
||||
val responseBody = webClient.httpGet(chapter.url.toAbsoluteUrl(domain)).body?.string()
|
||||
?: throw Exception("Response body is null for chapter page")
|
||||
|
||||
val responseBody = webClient.httpGet(chapter.url.toAbsoluteUrl(domain)).body.string()
|
||||
val chapterJsonRaw = responseBody.substringAfter("chapterJson: `", "").substringBefore("`", "")
|
||||
|
||||
val imageUrls: List<String>
|
||||
|
||||
Reference in New Issue
Block a user