mirror of
https://github.com/plexusorg/Plex.git
synced 2024-12-22 09:07:37 +00:00
Fix mute not having a permissions check
This commit is contained in:
parent
ff16347981
commit
0bbe2d06f6
@ -38,17 +38,10 @@ public class MuteCMD extends PlexCommand
|
||||
return messageComponent("playerMuted");
|
||||
}
|
||||
|
||||
if (isAdmin(getPlexPlayer(player)))
|
||||
if (silentCheckRank(player, Rank.ADMIN, "plex.mute"))
|
||||
{
|
||||
if (!isConsole(sender))
|
||||
{
|
||||
assert playerSender != null;
|
||||
PlexPlayer plexPlayer1 = getPlexPlayer(playerSender);
|
||||
if (!plexPlayer1.getRankFromString().isAtLeast(getPlexPlayer(player).getRankFromString()))
|
||||
{
|
||||
return messageComponent("higherRankThanYou");
|
||||
}
|
||||
}
|
||||
send(sender, messageComponent("higherRankThanYou"));
|
||||
return null;
|
||||
}
|
||||
|
||||
Punishment punishment = new Punishment(punishedPlayer.getUuid(), getUUID(sender));
|
||||
|
Loading…
Reference in New Issue
Block a user