Update filter to check for embeds

This commit is contained in:
Skylar Grant 2023-02-12 10:57:28 -05:00 committed by GitHub
parent e3ed133830
commit 077bb6c1b2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -531,7 +531,9 @@ const functions = {
const guild = await client.guilds.fetch(guildInfo.guildId);
// console.log(guildInfo instanceof GuildInfo);
const channel = await guild.channels.fetch(guildInfo.watchChannelId);
const filter = message => message.author.id != process.env.BOTID;
const filter = message => {
return message.author.id != process.env.BOTID && message.embeds != undefined;
}
const collector = channel.createMessageCollector({ filter });
collector.on('collect', message => {
if (message.embeds.length == 0) return;