From 13a1c03698716178822b81b4510e63908ce8e5dd Mon Sep 17 00:00:00 2001 From: jani270 <69345714+jani270@users.noreply.github.com> Date: Sun, 31 Dec 2023 14:26:12 +0100 Subject: Changed gatherJacobData to a regex and fixed a NFE (#980) * Fixed cleanSpecialChars not working Co-Authored-By: hannibal2 <24389977+hannibal002@users.noreply.github.com> * Changed logic of gatherjacobdata and fixed #808 Co-Authored-By: hannibal2 <24389977+hannibal002@users.noreply.github.com> * Removed unused import * Moved Pattern outside gatherJacobData * Made the regex more explicit. --------- Co-authored-by: hannibal2 <24389977+hannibal002@users.noreply.github.com> --- .../kotlin/io/github/moulberry/notenoughupdates/util/SidebarUtil.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main/kotlin/io') diff --git a/src/main/kotlin/io/github/moulberry/notenoughupdates/util/SidebarUtil.kt b/src/main/kotlin/io/github/moulberry/notenoughupdates/util/SidebarUtil.kt index d51c2ea9..47663bca 100644 --- a/src/main/kotlin/io/github/moulberry/notenoughupdates/util/SidebarUtil.kt +++ b/src/main/kotlin/io/github/moulberry/notenoughupdates/util/SidebarUtil.kt @@ -29,7 +29,7 @@ object SidebarUtil { fun readSidebarLines(cleanColor: Boolean = true, cleanSpecialCharacters: Boolean = true): List { var result = readRawSidebarLines() if (cleanColor) result = result.map { Utils.cleanColour(it) } - if (cleanSpecialCharacters) result.map { cleanTeamName(it) } + if (cleanSpecialCharacters) result = result.map { cleanTeamName(it) } return result } -- cgit