mirror of
https://github.com/gedoor/legado.git
synced 2024-09-01 09:34:25 +08:00
优化
This commit is contained in:
parent
a78cfffa11
commit
2bc386fe86
@ -39,9 +39,7 @@ class OkHttpStreamFetcher(private val url: GlideUrl, private val options: Option
|
||||
}
|
||||
val requestBuilder: Request.Builder = Request.Builder().url(url.toStringUrl())
|
||||
val headerMap = HashMap<String, String>()
|
||||
for ((key, value) in url.headers.entries) {
|
||||
headerMap[key] = value
|
||||
}
|
||||
headerMap.putAll(url.headers)
|
||||
options.get(OkHttpModelLoader.sourceOriginOption)?.let { sourceUrl ->
|
||||
val source = appDb.bookSourceDao.getBookSource(sourceUrl)
|
||||
?: appDb.rssSourceDao.getByKey(sourceUrl)
|
||||
|
Loading…
Reference in New Issue
Block a user