From 659ad4b26480ad5c43888135f24839ae7688cefa Mon Sep 17 00:00:00 2001 From: stevenyomi <95685115+stevenyomi@users.noreply.github.com> Date: Tue, 6 Sep 2022 22:10:49 +0800 Subject: [PATCH] MangaReader.to: simplify parseAuthor code (#13341) --- .../tachiyomi/extension/all/mangareaderto/MangaReader.kt | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/all/mangareaderto/src/eu/kanade/tachiyomi/extension/all/mangareaderto/MangaReader.kt b/src/all/mangareaderto/src/eu/kanade/tachiyomi/extension/all/mangareaderto/MangaReader.kt index ac431a0a2..b2f539501 100644 --- a/src/all/mangareaderto/src/eu/kanade/tachiyomi/extension/all/mangareaderto/MangaReader.kt +++ b/src/all/mangareaderto/src/eu/kanade/tachiyomi/extension/all/mangareaderto/MangaReader.kt @@ -133,12 +133,10 @@ open class MangaReader( return } } - val nodes = childNodes() val authorList = ArrayList(count) val artistList = ArrayList(count) for ((index, author) in authors.withIndex()) { - val nodeIndex = nodes.indexOf(author) - val textNode = nodes.getOrNull(nodeIndex + 1) as? TextNode + val textNode = author.nextSibling() as? TextNode val list = if (textNode != null && "(Art)" in textNode.wholeText) artistList else authorList list.add(text[index]) }