Merge pull request #2820 from spjspj/master

Modify the profanity filter to push it back to client side only.
This commit is contained in:
spjspj 2017-01-27 18:21:04 +11:00 committed by GitHub
commit 676d2a54dc
3 changed files with 17 additions and 9 deletions

View file

@ -192,6 +192,7 @@ public class ChatManager {
String command = message.substring(1).trim().toUpperCase(Locale.ENGLISH);
if (doError) {
message += new StringBuilder("<br/>Invalid User Command '" + message + "'.").append(COMMANDS_LIST).toString();
message += "<br/>Type <font color=green>\\w " + user.getName() + " profanity 0 (or 1 or 2)</font> to use/not use the profanity filter";
chatSessions.get(chatId).broadcastInfoToUser(user, message);
return true;
}
@ -227,6 +228,7 @@ public class ChatManager {
}
if (command.equals("L") || command.equals("LIST")) {
message += COMMANDS_LIST;
message += "<br/>Type <font color=green>\\w " + user.getName() + " profanity 0 (or 1 or 2)</font> to use/not use the profanity filter";
chatSessions.get(chatId).broadcastInfoToUser(user, message);
return true;
}