From c6916d49d1bfea0ab9f67bed8cb52505ec061109 Mon Sep 17 00:00:00 2001 From: Claude Date: Sat, 29 Aug 2026 15:34:47 +0000 Subject: [PATCH] refactor: keep the bracket-peel helper off the public surface `nip19OpeningPunctuationLength` has one caller, inside this file. Nothing outside needs it, and the behaviour is covered through `parseText`. --- .../vitorpamplona/amethyst/commons/richtext/RichTextParser.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/richtext/RichTextParser.kt b/commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/richtext/RichTextParser.kt index fa28712e73..f4ec7e1d68 100644 --- a/commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/richtext/RichTextParser.kt +++ b/commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/richtext/RichTextParser.kt @@ -676,7 +676,7 @@ class RichTextParser { * the URI inside the parentheses and [fixMissingSpaces] separates it. Bare * `npub1...`/`@npub1...` are not URIs, so nothing splits them; this does. */ - fun nip19OpeningPunctuationLength(word: String): Int { + private fun nip19OpeningPunctuationLength(word: String): Int { if (word.isEmpty() || !isNip19OpeningPunctuation(word[0])) return 0 var i = 1