二级目录解析的卷连接为空 阅读界面的链接返回为目录页的链接

pull/1527/head
Xwite 3 years ago
parent baccd099e6
commit 2ddb8cebe7
  1. 2
      app/src/main/java/io/legado/app/data/entities/BookChapter.kt

@ -109,6 +109,8 @@ data class BookChapter(
} }
fun getAbsoluteURL(): String { fun getAbsoluteURL(): String {
//二级目录解析的卷链接为空 返回目录页的链接
if (url.startsWith(title) && isVolume) return baseUrl
val urlMatcher = AnalyzeUrl.paramPattern.matcher(url) val urlMatcher = AnalyzeUrl.paramPattern.matcher(url)
val urlBefore = if (urlMatcher.find()) url.substring(0, urlMatcher.start()) else url val urlBefore = if (urlMatcher.find()) url.substring(0, urlMatcher.start()) else url
val urlAbsoluteBefore = NetworkUtils.getAbsoluteURL(baseUrl, urlBefore) val urlAbsoluteBefore = NetworkUtils.getAbsoluteURL(baseUrl, urlBefore)

Loading…
Cancel
Save