diff --git a/website/server/controllers/api-v3/chat.js b/website/server/controllers/api-v3/chat.js index 23ef1ad642..20d3ed885d 100644 --- a/website/server/controllers/api-v3/chat.js +++ b/website/server/controllers/api-v3/chat.js @@ -15,7 +15,7 @@ import nconf from 'nconf'; import Bluebird from 'bluebird'; import bannedWords from '../../libs/bannedWords'; import { TAVERN_ID } from '../../models/group'; -import bannedSlurs from '../../bannedSlurs'; +import bannedSlurs from '../../libs/bannedSlurs'; const FLAG_REPORT_EMAILS = nconf.get('FLAG_REPORT_EMAIL').split(',').map((email) => { return { email, canSend: true }; diff --git a/website/server/bannedSlurs.js b/website/server/libs/bannedSlurs.js similarity index 51% rename from website/server/bannedSlurs.js rename to website/server/libs/bannedSlurs.js index 2afcd1ad2b..7b2cd55a8d 100644 --- a/website/server/bannedSlurs.js +++ b/website/server/libs/bannedSlurs.js @@ -1,7 +1,7 @@ /* eslint-disable no-multiple-empty-lines */ // CONTENT WARNING: -// This file contains slurs, swear words, religious oaths, and words related to addictive substance and adult topics. +// This file contains slurs on race, gender, sexual orientation, etc. // Do not read this file if you do not want to be exposed to those words. // The words are stored in an array called `bannedSlurs` which is then exported with `module.exports = bannedSlurs;` // This file does not contain any other code. @@ -51,6 +51,37 @@ -let bannedSlurs = ['TEST_PLACEHOLDER_SLUR_WORD_HERE']; + + + + + + + + +let bannedSlurs = [ + 'TEST_PLACEHOLDER_SLUR_WORD_HERE', + + 'nigger', + 'niggers', + 'nigga', + 'niggas', + 'fag', + 'fags', + 'faggot', + 'faggots', + 'whore', + 'whores', + 'slut', + 'sluts', + 'cunt', + 'cunts', + 'spic', + 'spics', + 'tranny', + 'trannies', + 'tard', + 'tards', +]; module.exports = bannedSlurs; diff --git a/website/server/libs/bannedWords.js b/website/server/libs/bannedWords.js index 0c8792c338..75de0c1398 100644 --- a/website/server/libs/bannedWords.js +++ b/website/server/libs/bannedWords.js @@ -116,26 +116,6 @@ let bannedWords = [ 'bitching', 'b\\*tch', - 'nigger', - 'niggers', - 'nigga', - 'niggas', - 'fag', - 'fags', - 'faggot', - 'faggots', - 'whore', - 'whores', - 'slut', - 'sluts', - 'cunt', - 'cunts', - 'spic', - 'spics', - 'tranny', - 'trannies', - 'tard', - 'tards', 'retard', 'retards', 'bastard',