diff --git a/.gitignore b/.gitignore index 89a26f4..166641b 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,3 @@ -/.idea/artifacts -/.idea/libraries -/.idea/workspace.xml -/.idea/modules.xml -/.idea/uiDesigner.xml +/.idea/ target/ out/ \ No newline at end of file diff --git a/src/main/java/me/totalfreedom/tfguilds/command/SetRankSubcommand.java b/src/main/java/me/totalfreedom/tfguilds/command/SetRankSubcommand.java index b4ac17e..967a3ec 100644 --- a/src/main/java/me/totalfreedom/tfguilds/command/SetRankSubcommand.java +++ b/src/main/java/me/totalfreedom/tfguilds/command/SetRankSubcommand.java @@ -56,12 +56,13 @@ public class SetRankSubcommand extends Common implements CommandExecutor return true; } - String name = StringUtils.join(args, " ", 2, args.length); - if (name.toLowerCase().equals("none")) + String name = StringUtils.join(args, " ", 2, args.length).toLowerCase(); + if (name.equals("none")) { for (GuildRank gr : guild.getRanks()) { gr.getMembers().remove(r.getUniqueId()); + gr.save(); } sender.sendMessage(tl(PREFIX + "Removed the rank of %s%" + r.getName() + "%p% in your guild.")); @@ -80,6 +81,7 @@ public class SetRankSubcommand extends Common implements CommandExecutor for (GuildRank gr : guild.getRanks()) { gr.getMembers().remove(r.getUniqueId()); + gr.save(); } rank.getMembers().add(r.getUniqueId());