mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-09 16:13:31 +01:00
Slightly simplify logic in APIMessage.transformOptions
This commit is contained in:
@@ -287,13 +287,9 @@ class APIMessage {
|
||||
|
||||
if (!options) {
|
||||
options = {};
|
||||
}
|
||||
|
||||
if (options instanceof MessageEmbed) {
|
||||
} else if (options instanceof MessageEmbed) {
|
||||
return isWebhook ? { content, embeds: [options], ...extra } : { content, embed: options, ...extra };
|
||||
}
|
||||
|
||||
if (options instanceof MessageAttachment) {
|
||||
} else if (options instanceof MessageAttachment) {
|
||||
return { content, files: [options], ...extra };
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user