From 2f823a9916cdd93ccb3275ad209ff363a88ae75f Mon Sep 17 00:00:00 2001 From: dowoge Date: Wed, 21 Jun 2023 00:42:07 -0400 Subject: [PATCH] better regex --- src/main/java/testplugin/plugin/Events.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/testplugin/plugin/Events.java b/src/main/java/testplugin/plugin/Events.java index 4bcd4e3..ca8557a 100644 --- a/src/main/java/testplugin/plugin/Events.java +++ b/src/main/java/testplugin/plugin/Events.java @@ -66,7 +66,7 @@ public class Events implements Listener { DiscordWebhook Webhook = new DiscordWebhook(webhookURL); - Webhook.setContent('<' + player.getName() + "> " + message.replaceAll("(?)","`$1`")); + Webhook.setContent('<' + player.getName() + "> " + message.replaceAll("(<[@#]\\S+>|@\\S+|#\\S+)","`$1`")); try { Webhook.execute();