forked from Supositware/Haha-Yes
Allow choosing multiple formats
This commit is contained in:
parent
3dad025bb6
commit
14ee901846
1 changed files with 3 additions and 0 deletions
|
@ -61,6 +61,8 @@ module.exports = {
|
|||
new MessageSelectMenu()
|
||||
.setCustomId('downloadQuality')
|
||||
.setPlaceholder('Nothing selected')
|
||||
.setMinValues(1)
|
||||
.setMaxValues(2)
|
||||
.addOptions(options),
|
||||
);
|
||||
|
||||
|
@ -89,6 +91,7 @@ async function download(url, interaction) {
|
|||
|
||||
if (interaction.customId === 'downloadQuality') {
|
||||
format = interaction.values[0];
|
||||
if (interaction.values[1]) format += '+' + interaction.values[1];
|
||||
}
|
||||
|
||||
downloadVideo(url, interaction.id, format)
|
||||
|
|
Loading…
Reference in a new issue