diff --git a/index.js b/index.js index b30daba..5a3886f 100644 --- a/index.js +++ b/index.js @@ -22,10 +22,12 @@ client.on('messageDelete', message => { const messageAvatar = message.author.avatarURL(); const messageID = message.id; let messageAuthor; - if (message.author) { + if (message) { messageAuthor = message.author.tag; } else { - messageAuthor = "Someone else deleted this message" + messageAuthor = "Someone else deleted this message"; + messageContent = "Unknown"; + messageID = "Unknown"; } const deleteEmbed = new Discord.MessageEmbed() .setTitle('Message Deleted')