mirror of
https://github.com/songoda/UltimateModeration.git
synced 2025-02-07 07:01:24 +01:00
Fix for spy in gui.
This commit is contained in:
parent
f66a1db42d
commit
63a0bb285b
@ -19,7 +19,13 @@ public class CommandSpy extends AbstractCommand {
|
||||
}
|
||||
|
||||
public static void spy(OfflinePlayer player, Player senderP) {
|
||||
|
||||
|
||||
UltimateModeration instance = UltimateModeration.getInstance();
|
||||
if (player == senderP) {
|
||||
senderP.sendMessage(instance.getReferences().getPrefix() + "You cannot spy on yourself.");
|
||||
return;
|
||||
}
|
||||
boolean didVanish = false;
|
||||
if (!CommandVanish.isVanished(senderP)) {
|
||||
didVanish = true;
|
||||
@ -58,11 +64,6 @@ public class CommandSpy extends AbstractCommand {
|
||||
return ReturnType.FAILURE;
|
||||
}
|
||||
|
||||
if (player == senderP) {
|
||||
sender.sendMessage(instance.getReferences().getPrefix() + "You cannot spy on yourself.");
|
||||
return ReturnType.FAILURE;
|
||||
}
|
||||
|
||||
spy(player, senderP);
|
||||
|
||||
return ReturnType.SUCCESS;
|
||||
|
Loading…
Reference in New Issue
Block a user