TM: Fix requests (#765)

This commit is contained in:
beerpsi 2024-01-29 02:38:33 +07:00 committed by Draff
parent cabade3e41
commit bcfc74ef31
2 changed files with 5 additions and 3 deletions

View File

@ -1,7 +1,7 @@
ext { ext {
extName = 'Tsuki Mangás' extName = 'Tsuki Mangás'
extClass = '.TsukiMangas' extClass = '.TsukiMangas'
extVersionCode = 2 extVersionCode = 3
isNsfw = true isNsfw = true
} }

View File

@ -46,7 +46,9 @@ class TsukiMangas : HttpSource() {
.build() .build()
} }
override fun headersBuilder() = super.headersBuilder().add("Referer", "$baseUrl/") override fun headersBuilder() = super.headersBuilder()
.add("Referer", "$baseUrl/")
.add("X-Requested", "HttpsRequest")
private val json: Json by injectLazy() private val json: Json by injectLazy()
@ -268,6 +270,6 @@ class TsukiMangas : HttpSource() {
private const val MAIN_CDN = "https://cdn.tsuki-mangas.com/tsuki" private const val MAIN_CDN = "https://cdn.tsuki-mangas.com/tsuki"
private const val SECONDARY_CDN = "https://cdn2.tsuki-mangas.com" private const val SECONDARY_CDN = "https://cdn2.tsuki-mangas.com"
private const val API_PATH = "/api/d1" private const val API_PATH = "/api/v3"
} }
} }