From 6ba115ebd6be0f9e7573d316c6cdb5ee50f94f6e Mon Sep 17 00:00:00 2001 From: hoodie13 <74173949+hoodie13@users.noreply.github.com> Date: Sat, 13 Mar 2021 00:01:11 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8E=BB=E9=99=A4=E6=AE=B5=E5=B0=BE=E7=A9=BA?= =?UTF-8?q?=E6=A0=BC=EF=BC=8C=E9=81=BF=E5=85=8D=E5=88=86=E8=A1=8C=E5=90=8E?= =?UTF-8?q?=E5=87=BA=E7=8E=B0=E7=A9=BA=E7=99=BD=E8=A1=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/src/main/java/io/legado/app/help/ContentProcessor.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/io/legado/app/help/ContentProcessor.kt b/app/src/main/java/io/legado/app/help/ContentProcessor.kt index ab3a60f04..b8787242b 100644 --- a/app/src/main/java/io/legado/app/help/ContentProcessor.kt +++ b/app/src/main/java/io/legado/app/help/ContentProcessor.kt @@ -65,7 +65,7 @@ class ContentProcessor(private val bookName: String, private val bookOrigin: Str } val contents = arrayListOf() content1.split("\n").forEach { - val str = it.replace("^[\\n\\s\\r]+".toRegex(), "") + val str = it.replace("^[\\n\\r]+".toRegex(), "").trim() if (contents.isEmpty()) { contents.add(title) if (str != title && str.isNotEmpty()) {