From e30d2a9ca73b42959982e9b7723a59a6f0bbd9c6 Mon Sep 17 00:00:00 2001 From: Horis <821938089@qq.com> Date: Sat, 7 Oct 2023 17:17:29 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/src/main/java/io/legado/app/model/localBook/EpubFile.kt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/io/legado/app/model/localBook/EpubFile.kt b/app/src/main/java/io/legado/app/model/localBook/EpubFile.kt index 506331ca8431..f71ee340e31d 100644 --- a/app/src/main/java/io/legado/app/model/localBook/EpubFile.kt +++ b/app/src/main/java/io/legado/app/model/localBook/EpubFile.kt @@ -348,7 +348,10 @@ class EpubFile(var book: Book) { durIndex = 0 while (i < contents.size) { val content = contents[i] - if (!content.mediaType.toString().contains("htm")) continue + if (!content.mediaType.toString().contains("htm")) { + i++ + continue + } /** * 检索到第一章href停止 * completeHref可能有fragment(#id) 必须去除