From 81c03e49d73a01a04768d733d8b2b7f022f6851e Mon Sep 17 00:00:00 2001 From: Sayamame-beans <61457993+Sayamame-beans@users.noreply.github.com> Date: Tue, 25 Jun 2024 18:25:23 +0900 Subject: [PATCH] fix: force option detection now considers newline --- src/main/kotlin/io/github/kobi32768/quotebot/Utility.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/kotlin/io/github/kobi32768/quotebot/Utility.kt b/src/main/kotlin/io/github/kobi32768/quotebot/Utility.kt index 8c84e2c..86818f8 100644 --- a/src/main/kotlin/io/github/kobi32768/quotebot/Utility.kt +++ b/src/main/kotlin/io/github/kobi32768/quotebot/Utility.kt @@ -16,7 +16,7 @@ fun List.containsAny(vararg substring: String): Boolean { } fun MessageReceivedEvent.isForce(): Boolean { - return this.message.contentDisplay.split(' ').containsAny("-f", "--force") + return this.message.contentDisplay.split(' ', '\n').containsAny("-f", "--force") } fun compress64(id: String): String {