Compare commits
2 commits
fd7ca30e1c
...
995634a4b2
Author | SHA1 | Date | |
---|---|---|---|
995634a4b2 | |||
3464736d85 |
2 changed files with 6 additions and 3 deletions
|
@ -30,7 +30,7 @@ export default {
|
|||
|
||||
await interaction.deferReply({ ephemeral: true });
|
||||
|
||||
utils.downloadVideo(url, interaction.id, 'mp4')
|
||||
utils.downloadVideo(url, interaction.id, 'bestvideo[height<=?480]+bestaudio/best')
|
||||
.then(async () => {
|
||||
const file = fs.readdirSync(os.tmpdir()).filter(fn => fn.startsWith(interaction.id));
|
||||
const output = `${os.tmpdir()}/${file}`;
|
||||
|
|
|
@ -411,13 +411,16 @@ export default {
|
|||
payload = messageArgs.slice(i).join(' ');
|
||||
}
|
||||
|
||||
if (messageArgs[i].startsWith('--')) {
|
||||
if (arg.type === ApplicationCommandOptionType.Boolean && !messageArgs[i].startsWith('--')) {
|
||||
continue;
|
||||
}
|
||||
else if (messageArgs[i].startsWith('--')) {
|
||||
payloadName = payload.substring(2);
|
||||
payload = true;
|
||||
j--;
|
||||
}
|
||||
|
||||
if (arg.type === ApplicationCommandOptionType.Mentionable) {
|
||||
if (arg.type === ApplicationCommandOptionType.Mentionable || arg.type === ApplicationCommandOptionType.User) {
|
||||
await message.guild.members.fetch();
|
||||
payload = message.mentions.members.first() ? message.mentions.members.first() : message.guild.members.cache.find(u => u.user.username.toLowerCase().includes(payload.toLowerCase()));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue