From 87cadbfb023d81547e2198a792a3ee629d16ad8f Mon Sep 17 00:00:00 2001 From: fullwall Date: Wed, 2 Dec 2020 22:16:04 +0800 Subject: [PATCH] Wrong index for /trait remove --- main/src/main/java/net/citizensnpcs/commands/TraitCommands.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main/src/main/java/net/citizensnpcs/commands/TraitCommands.java b/main/src/main/java/net/citizensnpcs/commands/TraitCommands.java index 7038c0e49..1def389b0 100644 --- a/main/src/main/java/net/citizensnpcs/commands/TraitCommands.java +++ b/main/src/main/java/net/citizensnpcs/commands/TraitCommands.java @@ -100,7 +100,7 @@ public class TraitCommands { public void remove(CommandContext args, CommandSender sender, NPC npc) throws CommandException { List removed = Lists.newArrayList(); List failed = Lists.newArrayList(); - for (String traitName : Splitter.on(',').split(args.getJoinedStrings(0))) { + for (String traitName : Splitter.on(',').split(args.getJoinedStrings(1))) { if (!sender.hasPermission("citizens.npc.trait." + traitName) && !sender.hasPermission("citizens.npc.trait.*")) { failed.add(String.format("%s: No permission", traitName));