1
0
Fork 0

delete message only if it can send message

akairo
loicbersier 4 years ago
parent 68dcc1875c
commit b60057e110

@ -270,8 +270,10 @@ class messageListener extends Listener {
let Attachment = (quote.attachments).array();
if (Attachment[0]) Embed.setImage(Attachment[0].url);
message.delete();
return message.channel.send(Embed);
return message.channel.send(Embed)
.then(() => {
message.delete();
});
}
}

Loading…
Cancel
Save