mirror of
https://github.com/EssentialsX/Essentials.git
synced 2024-12-24 10:09:50 +01:00
Mute and sudo should check for essentials.vanish.interact permission.
This commit is contained in:
parent
55cee73a48
commit
43f4a69760
@ -19,13 +19,9 @@ public class Commandgetpos extends EssentialsCommand
|
||||
{
|
||||
if (args.length > 0 && user.isAuthorized("essentials.getpos.others"))
|
||||
{
|
||||
final User otherUser = getPlayer(server, args, 0, true, false);
|
||||
if (!otherUser.isHidden() || user.isAuthorized("essentials.vanish.interact"))
|
||||
{
|
||||
outputPosition(user, otherUser.getLocation(), user.getLocation());
|
||||
return;
|
||||
}
|
||||
|
||||
final User otherUser = getPlayer(server, user, args, 0);
|
||||
outputPosition(user, otherUser.getLocation(), user.getLocation());
|
||||
return;
|
||||
}
|
||||
outputPosition(user, user.getLocation(), null);
|
||||
}
|
||||
|
@ -23,7 +23,7 @@ public class Commandmute extends EssentialsCommand
|
||||
throw new NotEnoughArgumentsException();
|
||||
}
|
||||
|
||||
final User player = getPlayer(server, args, 0, true, true);
|
||||
final User player = getPlayer(server, sender, args, 0);
|
||||
if (sender instanceof Player && !player.isMuted() && player.isAuthorized("essentials.mute.exempt"))
|
||||
{
|
||||
throw new Exception(_("muteExempt"));
|
||||
|
@ -27,7 +27,7 @@ public class Commandsudo extends EssentialsCommand
|
||||
throw new NotEnoughArgumentsException();
|
||||
}
|
||||
|
||||
final User user = getPlayer(server, args, 0, true, false);
|
||||
final User user = getPlayer(server, sender, args, 0);
|
||||
if(args[1].toLowerCase(Locale.ENGLISH).startsWith("c:"))
|
||||
{
|
||||
if (user.isAuthorized("essentials.sudo.exempt") && sender instanceof Player)
|
||||
|
Loading…
Reference in New Issue
Block a user