diff --git a/patches/api/Make-the-default-permission-message-configurable.patch b/patches/api/Make-the-default-permission-message-configurable.patch index a2f5763802..d29841a85e 100644 --- a/patches/api/Make-the-default-permission-message-configurable.patch +++ b/patches/api/Make-the-default-permission-message-configurable.patch @@ -77,7 +77,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 - target.sendMessage(ChatColor.RED + "I'm sorry, but you do not have permission to perform this command. Please contact the server administrators if you believe that this is a mistake."); // Paper start - use components for permissionMessage - } else if (!permissionMessage.equals(net.kyori.adventure.text.Component.empty())) { -+ net.kyori.adventure.text.Component permissionMessage = this.permissionMessage != null ? this.permissionMessage : net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializer.legacySection().deserialize(Bukkit.getPermissionMessage()); ++ net.kyori.adventure.text.Component permissionMessage = this.permissionMessage != null ? this.permissionMessage : Bukkit.permissionMessage(); + if (!permissionMessage.equals(net.kyori.adventure.text.Component.empty())) { target.sendMessage(permissionMessage.replaceText(net.kyori.adventure.text.TextReplacementConfig.builder().matchLiteral("<permission>").replacement(permission).build())); // Paper end diff --git a/patches/server/Make-the-default-permission-message-configurable.patch b/patches/server/Make-the-default-permission-message-configurable.patch index 4b8badec49..f51fe313a8 100644 --- a/patches/server/Make-the-default-permission-message-configurable.patch +++ b/patches/server/Make-the-default-permission-message-configurable.patch @@ -13,7 +13,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 private static boolean testPermission(CommandSender commandSender, String permission) { if (commandSender.hasPermission(BASE_PERM + permission) || commandSender.hasPermission("bukkit.command.paper")) return true; - commandSender.sendMessage(text("I'm sorry, but you do not have permission to perform this command. Please contact the server administrators if you believe that this is in error.", RED)); -+ commandSender.sendMessage(Bukkit.getPermissionMessage()); // Sorry, kashike ++ commandSender.sendMessage(Bukkit.permissionMessage()); return false; }