Skip to content

Commit

Permalink
EVENTS: remove from index.js, check if bot
Browse files Browse the repository at this point in the history
  • Loading branch information
UsrBinLuna committed Jun 14, 2024
1 parent 0c8974e commit f41da31
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 14 deletions.
9 changes: 5 additions & 4 deletions events/messageCreate.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,12 @@ module.exports = {


async execute(interaction) {

const { autoModeration } = require('./helper/automod');

const { autoModeration } = require('./helper/automod');

const message = interaction.content;
autoModeration(message, interaction);
const message = interaction.content;
if (interaction.author.bot) return;
autoModeration(message, interaction);

},

Expand Down
10 changes: 0 additions & 10 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,14 +66,4 @@ player.events.on('playerStart', (queue, track) => {
//player.events.on('debug', (queue, message) => console.log(`[DEBUG ${queue.guild.id}] ${message}`));

// He sees everything
client.on('messageCreate', message => {
// Ignore messages from the bot
if (message.author.bot) return;

//console.log(`Message from ${message.author.tag}: ${message.content}`);

// Warm up the grill
//autoModeration(message);
});

client.login(token);

0 comments on commit f41da31

Please sign in to comment.