Shorten Method

This commit is contained in:
RayzsYT committed 2024-06-09 23:16:08 +02:00
1 parent 8e7c4ba1fc
commit 869356846d
3 files changed
+3 -3

No files matched your search

@@ -30,7 +30,7 @@ public class BukkitBlockCommandListener implements Listener {
command = StringUtils.replaceFirst(command, "/", "");
command = StringUtils.getFirstArg(command);
command = StringUtils.replace(command, "", "\\", "<", ">", "&");
command = StringUtils.replaceTriggers(command, "", "\\", "<", ">", "&");
List<String> notificationMessage = MessageTranslator.replaceMessageList(Storage.ConfigSections.Messages.NOTIFICATION.ALERT, "%player%", player.getName(), "%command%", command, "%world%", worldName);
@@ -29,7 +29,7 @@ public class BungeeBlockCommandListener implements Listener {
command = StringUtils.replaceFirst(command, "/", "");
command = StringUtils.getFirstArg(command);
command = StringUtils.replace(command, "", "\\", "<", ">", "&");
command = StringUtils.replaceTriggers(command, "", "\\", "<", ">", "&");
if(rawCommand.equals("/")) return;
ServerInfo serverInfo = player.getServer().getInfo();
@@ -34,7 +34,7 @@ public class VelocityBlockCommandListener {
command = StringUtils.replaceFirst(command, "/", "");
command = StringUtils.getFirstArg(command);
command = StringUtils.replace(command, "", "\\", "<", ">", "&");
command = StringUtils.replaceTriggers(command, "", "\\", "<", ">", "&");
List<String> notificationMessage = MessageTranslator.replaceMessageList(Storage.ConfigSections.Messages.NOTIFICATION.ALERT, "%player%", player.getUsername(), "%command%", command, "%server%", serverName);