1 |
import { BanOptions, CommandInteraction, EmojiIdentifierResolvable, GuildMember, Interaction, Message, TextChannel, User } from 'discord.js'; |
import { BanOptions, CommandInteraction, EmojiIdentifierResolvable, FileOptions, GuildMember, Interaction, Message, TextChannel, User } from 'discord.js'; |
2 |
import BaseCommand from '../../utils/structures/BaseCommand'; |
import BaseCommand from '../../utils/structures/BaseCommand'; |
3 |
import DiscordClient from '../../client/Client'; |
import DiscordClient from '../../client/Client'; |
4 |
import CommandOptions from '../../types/CommandOptions'; |
import CommandOptions from '../../types/CommandOptions'; |
62 |
await member.send({ |
await member.send({ |
63 |
content: parsedContent.trim() === '' ? undefined : parsedContent, |
content: parsedContent.trim() === '' ? undefined : parsedContent, |
64 |
embeds, |
embeds, |
65 |
attachments: msg instanceof CommandInteraction ? undefined : [...msg.attachments.values()] |
files: msg instanceof CommandInteraction ? undefined : [...msg.attachments.map(a => ({ |
66 |
|
attachment: a.proxyURL, |
67 |
|
description: a.description, |
68 |
|
name: a.name |
69 |
|
} as FileOptions)).values()] |
70 |
}); |
}); |
71 |
|
|
72 |
if (options.isInteraction) { |
if (options.isInteraction) { |