[Fix] MMRCMS - Add Headers (#1695)

[Fix] MMRCMS - Add Headers
This commit is contained in:
happywillow0 2019-10-22 21:37:42 -04:00 committed by arkon
parent 21ef162980
commit 89a0b734f5
2 changed files with 4 additions and 4 deletions

View File

@ -5,7 +5,7 @@ ext {
appName = 'Tachiyomi: My Manga Reader CMS (Many sources)'
pkgNameSuffix = 'all.mmrcms'
extClass = '.MyMangaReaderCMSSources'
extVersionCode = 21
extVersionCode = 22
libVersion = '1.2'
}

View File

@ -31,7 +31,7 @@ class MyMangaReaderCMSSource(override val lang: String,
override val client: OkHttpClient = network.cloudflareClient
override fun popularMangaRequest(page: Int) = GET("$baseUrl/filterList?page=$page&sortBy=views&asc=false")
override fun popularMangaRequest(page: Int) = GET("$baseUrl/filterList?page=$page&sortBy=views&asc=false", headers)
override fun searchMangaRequest(page: Int, query: String, filters: FilterList): Request {
//Query overrides everything
val url: Uri.Builder
@ -43,10 +43,10 @@ class MyMangaReaderCMSSource(override val lang: String,
filters.filterIsInstance<UriFilter>()
.forEach { it.addToUri(url) }
}
return GET(url.toString())
return GET(url.toString(), headers)
}
override fun latestUpdatesRequest(page: Int) = GET("$baseUrl/filterList?page=$page&sortBy=last_release&asc=false")
override fun latestUpdatesRequest(page: Int) = GET("$baseUrl/filterList?page=$page&sortBy=last_release&asc=false", headers)
override fun popularMangaParse(response: Response) = internalMangaParse(response)
override fun searchMangaParse(response: Response): MangasPage {