mirror of
https://github.com/mihonapp/mihon.git
synced 2024-12-25 02:18:24 +01:00
Default headers are bad
This commit is contained in:
parent
8bd20c39aa
commit
9aa6da0642
@ -108,6 +108,7 @@ class MangaModelLoader(context: Context) : StreamModelLoader<Manga> {
|
|||||||
val source = sourceManager.get(manga.source) as? OnlineSource ?: return LazyHeaders.DEFAULT
|
val source = sourceManager.get(manga.source) as? OnlineSource ?: return LazyHeaders.DEFAULT
|
||||||
return cachedHeaders.getOrPut(manga.source) {
|
return cachedHeaders.getOrPut(manga.source) {
|
||||||
LazyHeaders.Builder().apply {
|
LazyHeaders.Builder().apply {
|
||||||
|
setHeader("User-Agent", null as? String)
|
||||||
for ((key, value) in source.headers.toMultimap()) {
|
for ((key, value) in source.headers.toMultimap()) {
|
||||||
addHeader(key, value[0])
|
addHeader(key, value[0])
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user