From 76e75f3601fff8494dcee7dfa8520f9f6d9e1cdd Mon Sep 17 00:00:00 2001 From: ChomeNS <95471003+ChomeNS@users.noreply.github.com> Date: Wed, 14 May 2025 16:44:10 +0700 Subject: [PATCH] fix: prefix self care not working for the Something went wrong while saving the prefix --- build-number.txt | 2 +- .../chomens_bot/selfCares/kaboom/extras/PrefixSelfCare.java | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/build-number.txt b/build-number.txt index e48c310f..3832db4f 100644 --- a/build-number.txt +++ b/build-number.txt @@ -1 +1 @@ -3187 \ No newline at end of file +3191 \ No newline at end of file diff --git a/src/main/java/me/chayapak1/chomens_bot/selfCares/kaboom/extras/PrefixSelfCare.java b/src/main/java/me/chayapak1/chomens_bot/selfCares/kaboom/extras/PrefixSelfCare.java index 4cdf95bd..134f1d87 100644 --- a/src/main/java/me/chayapak1/chomens_bot/selfCares/kaboom/extras/PrefixSelfCare.java +++ b/src/main/java/me/chayapak1/chomens_bot/selfCares/kaboom/extras/PrefixSelfCare.java @@ -17,12 +17,14 @@ public class PrefixSelfCare extends SelfCare { @Override public void onMessageReceived (final Component component, final String string) { - if (string.equals("You now have the tag: " + bot.config.selfCare.prefix.prefix)) { + if ( + string.equals("You now have the tag: " + bot.config.selfCare.prefix.prefix) + || string.equals("Something went wrong while saving the prefix. Please check console.") + ) { this.needsRunning = false; } else if ( string.startsWith("You no longer have a tag") || string.startsWith("You now have the tag: ") - || string.equals("Something went wrong while saving the prefix. Please check console.") ) { this.needsRunning = true; }