mirror of https://github.com/plexusorg/Plex.git
Fix permission node
This commit is contained in:
parent
6d5620887b
commit
4c458540bb
|
@ -21,7 +21,6 @@ import org.jetbrains.annotations.Nullable;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
import java.util.concurrent.CompletableFuture;
|
|
||||||
|
|
||||||
@CommandParameters(name = "pdebug", description = "Plex's debug command", usage = "/<command> <aliases <command> | redis-reset <player> | gamerules>")
|
@CommandParameters(name = "pdebug", description = "Plex's debug command", usage = "/<command> <aliases <command> | redis-reset <player> | gamerules>")
|
||||||
@CommandPermissions(permission = "plex.debug")
|
@CommandPermissions(permission = "plex.debug")
|
||||||
|
@ -93,6 +92,6 @@ public class DebugCMD extends PlexCommand
|
||||||
@Override
|
@Override
|
||||||
public @NotNull List<String> smartTabComplete(@NotNull CommandSender sender, @NotNull String alias, @NotNull String[] args) throws IllegalArgumentException
|
public @NotNull List<String> smartTabComplete(@NotNull CommandSender sender, @NotNull String alias, @NotNull String[] args) throws IllegalArgumentException
|
||||||
{
|
{
|
||||||
return args.length == 1 ? PlexUtils.getPlayerNameList() : ImmutableList.of();
|
return args.length == 1 && silentCheckPermission(sender, this.getPermission()) ? PlexUtils.getPlayerNameList() : ImmutableList.of();
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -61,11 +61,11 @@ public class RemoveLoginMessageCMD extends PlexCommand
|
||||||
{
|
{
|
||||||
if (args.length == 1)
|
if (args.length == 1)
|
||||||
{
|
{
|
||||||
if (silentCheckPermission(sender, "plex.removeloginmessage"))
|
if (silentCheckPermission(sender, "plex.removeloginmessage.others"))
|
||||||
{
|
{
|
||||||
return List.of("-o");
|
return List.of("-o");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return args.length == 2 && silentCheckPermission(sender, "plex.removeloginmessage") ? PlexUtils.getPlayerNameList() : ImmutableList.of();
|
return args.length == 2 && silentCheckPermission(sender, "plex.removeloginmessage.others") ? PlexUtils.getPlayerNameList() : ImmutableList.of();
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in New Issue