mirror of
https://github.com/JonnyBro/JaBa.git
synced 2024-11-22 05:04:58 +05:00
add image if attached in quote
This commit is contained in:
parent
b900207c44
commit
7a0a34cb98
1 changed files with 2 additions and 2 deletions
|
@ -68,6 +68,8 @@ class MessageCreate extends BaseEvent {
|
|||
]);
|
||||
|
||||
if (msg.attachments.size > 0) {
|
||||
if (msg.attachments.find(a => a.contentType.includes("image/"))) embed.setImage(msg.attachments.find(a => a.contentType.includes("image/")).url);
|
||||
|
||||
embed.addFields([
|
||||
{
|
||||
name: message.translate("misc:QUOTE_ATTACHED"),
|
||||
|
@ -91,8 +93,6 @@ class MessageCreate extends BaseEvent {
|
|||
|
||||
collector.on("collect", async i => {
|
||||
if (i.isButton() && i.customId === "quote_delete") {
|
||||
console.log(i.message);
|
||||
|
||||
if (i.message.deletable) i.message.delete();
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue