mirror of
https://github.com/Shiewk/SModeration.git
synced 2026-04-29 06:34:17 +02:00
Make the mute command require a positive duration
This commit is contained in:
@@ -59,6 +59,9 @@ public final class MuteCommand implements CommandProvider {
|
||||
}
|
||||
|
||||
public static void executeMute(UUID sender, UUID target, long duration, String reason) throws CommandSyntaxException {
|
||||
if (duration == 0){
|
||||
CommandUtil.errorTranslatable("smod.command.mute.fail.tooShort");
|
||||
}
|
||||
if (sender.equals(target)) {
|
||||
CommandUtil.errorTranslatable("smod.command.mute.fail.self");
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user