2024-08-17 11:46:19 -04:00
|
|
|
const { skipTrack } = require('../utils/queueManager');
|
2024-08-17 11:11:10 -04:00
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
name: 'skip',
|
2024-08-17 15:20:51 -04:00
|
|
|
description: 'Skip the current track',
|
2024-08-17 11:11:10 -04:00
|
|
|
execute(message) {
|
2024-08-17 11:23:30 -04:00
|
|
|
const guildId = message.guild.id;
|
2024-08-17 11:46:19 -04:00
|
|
|
const voiceChannel = message.member.voice.channel;
|
2024-08-17 11:23:30 -04:00
|
|
|
|
2024-08-17 11:46:19 -04:00
|
|
|
if (!voiceChannel) {
|
|
|
|
return message.reply('You need to be in a voice channel to skip music!');
|
2024-08-17 11:23:30 -04:00
|
|
|
}
|
2024-08-17 11:46:19 -04:00
|
|
|
|
2024-08-17 14:58:17 -04:00
|
|
|
skipTrack(guildId, voiceChannel);
|
2024-08-17 11:46:19 -04:00
|
|
|
message.channel.send('Skipped the current track!');
|
2024-08-17 11:11:10 -04:00
|
|
|
}
|
2024-08-17 11:23:30 -04:00
|
|
|
};
|