From 1c044c9072df02516fdcfadc5c1d220b7c8e06a4 Mon Sep 17 00:00:00 2001 From: Vitor Pamplona Date: Wed, 11 Mar 2026 14:12:02 -0400 Subject: [PATCH] If warning is blank, revert to defaults --- .../quartz/nip36SensitiveContent/ContentWarningTag.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/quartz/src/commonMain/kotlin/com/vitorpamplona/quartz/nip36SensitiveContent/ContentWarningTag.kt b/quartz/src/commonMain/kotlin/com/vitorpamplona/quartz/nip36SensitiveContent/ContentWarningTag.kt index af4214f66..200fb0481 100644 --- a/quartz/src/commonMain/kotlin/com/vitorpamplona/quartz/nip36SensitiveContent/ContentWarningTag.kt +++ b/quartz/src/commonMain/kotlin/com/vitorpamplona/quartz/nip36SensitiveContent/ContentWarningTag.kt @@ -36,7 +36,7 @@ class ContentWarningTag( fun parse(tags: Array): ContentWarningTag? { ensure(tags[0] == TAG_NAME) { return null } - return ContentWarningTag(tags.getOrNull(1).ifBlank { null }) + return ContentWarningTag(tags.getOrNull(1)?.ifBlank { null }) } fun assemble() = arrayOfNotNull(TAG_NAME)