2022-12-26 05:22:08 +01:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
|
|
From: NonSwag <mrminecraft00@gmail.com>
|
|
|
|
Date: Thu, 8 Dec 2022 20:25:05 +0100
|
|
|
|
Subject: [PATCH] Add missing SpigotConfig logCommands check
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
2023-12-12 07:02:06 +01:00
|
|
|
index 8ff416bbb4743af7bb4f3a1b30e34bd288059fa9..38f34e26dc515b66fe4bc38285b9813023c0ed97 100644
|
2022-12-26 05:22:08 +01:00
|
|
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
2023-12-09 00:14:42 +01:00
|
|
|
@@ -2135,7 +2135,9 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
|
2022-12-26 05:22:08 +01:00
|
|
|
private void performChatCommand(ServerboundChatCommandPacket packet, LastSeenMessages lastSeenMessages) {
|
|
|
|
// CraftBukkit start
|
|
|
|
String command = "/" + packet.command();
|
|
|
|
+ if (org.spigotmc.SpigotConfig.logCommands) { // Paper
|
|
|
|
ServerGamePacketListenerImpl.LOGGER.info(this.player.getScoreboardName() + " issued server command: " + command);
|
|
|
|
+ } // Paper
|
|
|
|
|
2023-10-27 01:34:58 +02:00
|
|
|
PlayerCommandPreprocessEvent event = new PlayerCommandPreprocessEvent(this.getCraftPlayer(), command, new LazyPlayerSet(this.server));
|
2022-12-26 05:22:08 +01:00
|
|
|
this.cserver.getPluginManager().callEvent(event);
|