Resolve bug when checking if user is in channel
This commit is contained in:
@@ -130,8 +130,8 @@ module.exports = {
|
||||
try{
|
||||
const guildId = interaction.guild.id;
|
||||
const presetName = interaction.options.getString('preset');
|
||||
if (!interaction.member.voice.channel) return interaction.editReply(`You need to be in a voice channel, ${interaction.user}`)
|
||||
const channelId = interaction.member.voice.channel.id;
|
||||
if (!channelId) return interaction.editReply(`You need to be in a voice channel, ${interaction.user}`);
|
||||
log.DEBUG(`Join requested by: ${interaction.user.username}, to: '${presetName}', in channel: ${channelId} / ${guildId}`);
|
||||
|
||||
const connections = await getAllConnections();
|
||||
|
||||
Reference in New Issue
Block a user