diff --git a/patches/server/0745-Vanilla-command-permission-fixes.patch b/patches/server/0745-Vanilla-command-permission-fixes.patch index 4b200f28e9..46e803d4e5 100644 --- a/patches/server/0745-Vanilla-command-permission-fixes.patch +++ b/patches/server/0745-Vanilla-command-permission-fixes.patch @@ -30,7 +30,7 @@ index 899008b2980d13f1be6280cd8cb959c53a29bebf..f875507241ac6769545e91cd3285232b private RedirectModifier modifier = null; private boolean forks; diff --git a/src/main/java/net/minecraft/commands/Commands.java b/src/main/java/net/minecraft/commands/Commands.java -index 816ea85a5880123c970d227d61426a0ae2b9539f..6fec6a47538da4c0c5a4505e9bedf492bb3376dd 100644 +index 816ea85a5880123c970d227d61426a0ae2b9539f..b7c24a7ff4dc50d03f74b21a0b353d0ce559b4d4 100644 --- a/src/main/java/net/minecraft/commands/Commands.java +++ b/src/main/java/net/minecraft/commands/Commands.java @@ -204,6 +204,13 @@ public class Commands { @@ -40,7 +40,7 @@ index 816ea85a5880123c970d227d61426a0ae2b9539f..6fec6a47538da4c0c5a4505e9bedf492 + // Paper start + for (final CommandNode node : this.dispatcher.getRoot().getChildren()) { + if (node.getRequirement() == com.mojang.brigadier.builder.ArgumentBuilder.defaultRequirement()) { -+ node.requirement = stack -> stack.getBukkitSender().hasPermission(org.bukkit.craftbukkit.command.VanillaCommandWrapper.getPermission(node)); ++ node.requirement = stack -> stack.source == CommandSource.NULL || stack.getBukkitSender().hasPermission(org.bukkit.craftbukkit.command.VanillaCommandWrapper.getPermission(node)); + } + } + // Paper end