diff --git a/src/main/java/com/gmail/nossr50/party/commands/PartyExpShareCommand.java b/src/main/java/com/gmail/nossr50/party/commands/PartyExpShareCommand.java index bae7e3850..68d8a0780 100644 --- a/src/main/java/com/gmail/nossr50/party/commands/PartyExpShareCommand.java +++ b/src/main/java/com/gmail/nossr50/party/commands/PartyExpShareCommand.java @@ -14,7 +14,6 @@ import com.gmail.nossr50.util.Permissions; import com.gmail.nossr50.util.Users; public class PartyExpShareCommand implements CommandExecutor { - private Player player; private Party playerParty; @Override @@ -26,8 +25,7 @@ public class PartyExpShareCommand implements CommandExecutor { switch (args.length) { case 2: - player = (Player) sender; - playerParty = Users.getPlayer(player).getParty(); + playerParty = Users.getPlayer((Player) sender).getParty(); if (args[1].equalsIgnoreCase("none") || args[1].equalsIgnoreCase("off") || args[1].equalsIgnoreCase("false")) { handleChangingShareMode(ShareMode.NONE); diff --git a/src/main/java/com/gmail/nossr50/party/commands/PartyItemShareCommand.java b/src/main/java/com/gmail/nossr50/party/commands/PartyItemShareCommand.java index 7cbd90c2d..d204250c3 100644 --- a/src/main/java/com/gmail/nossr50/party/commands/PartyItemShareCommand.java +++ b/src/main/java/com/gmail/nossr50/party/commands/PartyItemShareCommand.java @@ -14,7 +14,6 @@ import com.gmail.nossr50.util.Permissions; import com.gmail.nossr50.util.Users; public class PartyItemShareCommand implements CommandExecutor { - private Player player; private Party playerParty; @Override @@ -26,8 +25,7 @@ public class PartyItemShareCommand implements CommandExecutor { switch (args.length) { case 2: - player = (Player) sender; - playerParty = Users.getPlayer(player).getParty(); + playerParty = Users.getPlayer((Player) sender).getParty(); if (args[1].equalsIgnoreCase("none") || args[1].equalsIgnoreCase("off") || args[1].equalsIgnoreCase("false")) { handleChangingShareMode(ShareMode.NONE);