blob: 46e879519f83eba1d1bcb41830c88cf1dc184b58 [file] [log] [blame]
pineafan32767212022-03-14 21:27:39 +00001const {addLog} = require('../scripts/addLogs');
2
3module.exports = {
4 name:'messageCreate',
5 once:false,
6 async execute(message) {
7
8 const guildConfig = require(`../data/guilds/${message.guild.id}/config.json`);
9 if(guildConfig.images.enabled) {
10
11 }
12 if(guildConfig.wordFilter.enabled) {
13 for(word of guildConfig.wordFilter.words.strict) {
14 if(message.content.toLowerCase().includes(word)) {
15 message.delete();
16 // message.channel.send(`${message.author} has been warned for using a banned word.`);
17 break;
18 }
19 }
20 for(word of message.content.split(' ')) {
21 if(guildConfig.wordFilter.words.soft.includes(word)) {
22 message.delete();
23 // message.channel.send(`${message.author} has been warned for using a banned word.`);
24 break;
25 }
26 }
27
28 }
29
30
31 }
32}