From 8f34193f7614cba630195a378a59c8fdf4bc8ed4 Mon Sep 17 00:00:00 2001 From: Adam CAVILLON Date: Thu, 4 Jul 2024 22:43:39 +0200 Subject: [PATCH] =?UTF-8?q?[Code]=20Utilisation=20du=20pr=C3=A9fix=20de=20?= =?UTF-8?q?commandes=20sur=20la=20commande=20/version?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/fr/communaywen/core/commands/VersionCommand.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/fr/communaywen/core/commands/VersionCommand.java b/src/main/java/fr/communaywen/core/commands/VersionCommand.java index efb489ae..d819e98a 100644 --- a/src/main/java/fr/communaywen/core/commands/VersionCommand.java +++ b/src/main/java/fr/communaywen/core/commands/VersionCommand.java @@ -1,5 +1,6 @@ package fr.communaywen.core.commands; +import fr.communaywen.core.AywenCraftPlugin; import org.bukkit.command.Command; import org.bukkit.command.CommandExecutor; import org.bukkit.command.CommandSender; @@ -19,7 +20,7 @@ public boolean onCommand(CommandSender sender, Command command, String label, St if (command.getName().equalsIgnoreCase("version")) { if (sender instanceof Player) { Player player = (Player) sender; - if (!player.hasPermission("ayw.version")) { + if (!player.hasPermission(AywenCraftPlugin.formatPermission("version"))) { player.sendMessage("Vous n'avez pas la permission d'utiliser cette commande."); return true; }