Browse Source

Return if edited message contains an embed

master
Abheek Dhawan 4 years ago
parent
commit
9692e64939
  1. 3
      bot.js

3
bot.js

@ -711,6 +711,9 @@ client.on('messageDeleteBulk', messages => {
}); });
client.on('messageUpdate', (originalMessage, editedMessage) => { client.on('messageUpdate', (originalMessage, editedMessage) => {
if (editedMessage.embeds.length > 0) {
return;
}
editedMessage.channel.messages.fetch(editedMessage.id) editedMessage.channel.messages.fetch(editedMessage.id)
.then(editedMessage => { .then(editedMessage => {
const editEmbed = new Discord.MessageEmbed() const editEmbed = new Discord.MessageEmbed()

Loading…
Cancel
Save