Merge pull request #2715 from bhickey/bowdlerize

Censor the word "penis"
This commit is contained in:
LevelX2 2016-12-25 10:57:36 +01:00 committed by GitHub
commit 233096dc1b

View file

@ -107,7 +107,7 @@ public class ChatManager {
} }
private boolean containsSwearing(String message) { private boolean containsSwearing(String message) {
if (message != null && message.toLowerCase().matches("^.*(anal|asshole|balls|bastard|bitch|blowjob|cock|crap|cunt|cum|damn|dick|dildo|douche|fag|fuck|idiot|moron|piss|prick|pussy|rape|rapist|sex|screw|shit|slut|vagina).*$")) { if (message != null && message.toLowerCase().matches("^.*(anal|asshole|balls|bastard|bitch|blowjob|cock|crap|cunt|cum|damn|dick|dildo|douche|fag|fuck|idiot|moron|penis|piss|prick|pussy|rape|rapist|sex|screw|shit|slut|vagina).*$")) {
return true; return true;
} }
return false; return false;