pull/32/head
kunfei 5 years ago
parent 70f10e7ff5
commit ea8ae6aa96
  1. 2
      app/src/main/java/io/legado/app/model/webbook/BookChapterList.kt

@ -60,11 +60,9 @@ object BookChapterList {
} else if (chapterData.nextUrl.size > 1) { } else if (chapterData.nextUrl.size > 1) {
val chapterDataList = arrayListOf<ChapterData<String>>() val chapterDataList = arrayListOf<ChapterData<String>>()
for (item in chapterData.nextUrl) { for (item in chapterData.nextUrl) {
if (!nextUrlList.contains(item)) {
val data = ChapterData(nextUrl = item) val data = ChapterData(nextUrl = item)
chapterDataList.add(data) chapterDataList.add(data)
} }
}
for (item in chapterDataList) { for (item in chapterDataList) {
withContext(coroutineScope.coroutineContext) { withContext(coroutineScope.coroutineContext) {
val nextResponse = AnalyzeUrl(ruleUrl = item.nextUrl, book = book).getResponseAsync().await() val nextResponse = AnalyzeUrl(ruleUrl = item.nextUrl, book = book).getResponseAsync().await()

Loading…
Cancel
Save