Skip to content

Commit

Permalink
Add another permission to /ignoreafk <player>
Browse files Browse the repository at this point in the history
  • Loading branch information
andrew121410 committed Jul 11, 2024
1 parent d5267d8 commit 31461aa
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@ public boolean onCommand(CommandSender sender, Command cmd, String label, String

handleIgnoreAfk(sender, null);
} else if (args.length == 1) { // /ignoreafk <player>
if (!sender.hasPermission("world16.ignoreafk.other")) {
api.sendPermissionErrorMessage(sender);
return true;
}

Player target = this.plugin.getServer().getPlayerExact(args[0]);
if (target == null) {
sender.sendMessage(Translate.miniMessage("<red>Player not found."));
Expand Down

0 comments on commit 31461aa

Please sign in to comment.