APRK01 commited on
Commit Β·
79b4bed
1
Parent(s): 6bab161
fix: add image support to createEmbed utility
Browse files- src/utils/embeds.js +2 -0
src/utils/embeds.js
CHANGED
|
@@ -10,6 +10,7 @@ function createEmbed({
|
|
| 10 |
color = Colors.PRIMARY,
|
| 11 |
fields = [],
|
| 12 |
thumbnail = null,
|
|
|
|
| 13 |
footer = 'WSB β Wyvern Softworks Bot',
|
| 14 |
timestamp = true,
|
| 15 |
} = {}) {
|
|
@@ -18,6 +19,7 @@ function createEmbed({
|
|
| 18 |
if (title) embed.setTitle(title);
|
| 19 |
if (description) embed.setDescription(description);
|
| 20 |
if (thumbnail) embed.setThumbnail(thumbnail);
|
|
|
|
| 21 |
if (fields.length) embed.addFields(fields);
|
| 22 |
if (footer) embed.setFooter({ text: footer });
|
| 23 |
if (timestamp) embed.setTimestamp();
|
|
|
|
| 10 |
color = Colors.PRIMARY,
|
| 11 |
fields = [],
|
| 12 |
thumbnail = null,
|
| 13 |
+
image = null,
|
| 14 |
footer = 'WSB β Wyvern Softworks Bot',
|
| 15 |
timestamp = true,
|
| 16 |
} = {}) {
|
|
|
|
| 19 |
if (title) embed.setTitle(title);
|
| 20 |
if (description) embed.setDescription(description);
|
| 21 |
if (thumbnail) embed.setThumbnail(thumbnail);
|
| 22 |
+
if (image) embed.setImage(image);
|
| 23 |
if (fields.length) embed.addFields(fields);
|
| 24 |
if (footer) embed.setFooter({ text: footer });
|
| 25 |
if (timestamp) embed.setTimestamp();
|