mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-22 13:16:45 +01:00
Merge pull request #3890 from OverCrave/master
Fix adminchat returning too early if send by the console
This commit is contained in:
commit
c509daff9f
@ -55,14 +55,13 @@ public abstract class ChatCommand implements TabExecutor {
|
||||
return true;
|
||||
|
||||
case 1:
|
||||
if (!CommandUtils.hasPlayerDataKey(sender)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
if (CommandUtils.shouldEnableToggle(args[0])) {
|
||||
if (CommandUtils.noConsoleUsage(sender)) {
|
||||
return true;
|
||||
}
|
||||
if (!CommandUtils.hasPlayerDataKey(sender)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
enableChatMode(UserManager.getPlayer(sender.getName()), sender);
|
||||
return true;
|
||||
@ -72,6 +71,9 @@ public abstract class ChatCommand implements TabExecutor {
|
||||
if (CommandUtils.noConsoleUsage(sender)) {
|
||||
return true;
|
||||
}
|
||||
if (!CommandUtils.hasPlayerDataKey(sender)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
disableChatMode(UserManager.getPlayer(sender.getName()), sender);
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user