Player should not be able to send empty shout/question messages (#3341)

This commit is contained in:
pop4959 2020-05-28 11:45:05 -07:00 committed by GitHub
parent db729241c9
commit 9e01a1a427
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -38,9 +38,9 @@ public abstract class EssentialsChatPlayer implements Listener {
final char prefix = message.charAt(0);
if (prefix == ess.getSettings().getChatShout()) {
return "shout";
return message.length() > 1 ? "shout" : "";
} else if (prefix == ess.getSettings().getChatQuestion()) {
return "question";
return message.length() > 1 ? "question" : "";
} else {
return "";
}