9
0
mirror of https://github.com/HibiscusMC/HMCCosmetics.git synced 2025-12-30 20:39:13 +00:00

Wardrobe command now supports another player properly

This commit is contained in:
LoJoSho
2023-01-02 18:50:39 -06:00
parent 17d2554e6c
commit 741cdb7132

View File

@@ -143,7 +143,7 @@ public class CosmeticCommand implements CommandExecutor {
Player player = null;
if (sender instanceof Player) player = ((Player) sender).getPlayer();
if (args.length >= 3) player = Bukkit.getPlayer(args[2]);
if (args.length >= 2) player = Bukkit.getPlayer(args[1]);
if (!player.hasPermission("HMCCosmetic.wardrobe")) {
MessagesUtil.sendMessage(sender, "no-permission");