RC: fix referer (#653)

fix referer
This commit is contained in:
AwkwardPeak7 2024-01-26 09:39:49 +05:00 committed by Draff
parent 0a0251c9d7
commit 6acac9416c
2 changed files with 2 additions and 3 deletions

View File

@ -1,7 +1,7 @@
ext {
extName = 'Rizz Comic'
extClass = '.RizzComic'
extVersionCode = 2
extVersionCode = 3
}
apply from: "$rootDir/common.gradle"

View File

@ -101,7 +101,7 @@ class RizzComic : HttpSource(), ConfigurableSource {
updateCache()
}
return urlPrefix!!
return urlPrefix ?: throw Exception("Unable to update dynamic urls")
}
override fun popularMangaRequest(page: Int) = searchMangaRequest(page, "", SortFilter.POPULAR)
@ -267,7 +267,6 @@ class RizzComic : HttpSource(), ConfigurableSource {
override fun imageRequest(page: Page): Request {
val newHeaders = headersBuilder()
.set("Accept", "image/avif,image/webp,image/png,image/jpeg,*/*")
.set("Referer", page.url)
.build()
return GET(page.imageUrl!!, newHeaders)