fix(commands/voice/join): only join when author is in voice channel

This commit is contained in:
Ryan 2025-02-12 11:55:44 -05:00
parent ea09f291e5
commit c8c4756cc3
Signed by: ErrorNoInternet
GPG Key ID: 2486BFB7B1E6A4A3

View File

@ -1,5 +1,3 @@
import disnake
import utils import utils
from .utils import command_allowed from .utils import command_allowed
@ -10,8 +8,6 @@ async def join(message):
return await message.guild.voice_client.move_to(message.channel) return await message.guild.voice_client.move_to(message.channel)
elif message.author.voice: elif message.author.voice:
await message.author.voice.channel.connect() await message.author.voice.channel.connect()
elif isinstance(message.channel, disnake.VoiceChannel):
await message.channel.connect()
else: else:
await utils.reply(message, "you are not connected to a voice channel!") await utils.reply(message, "you are not connected to a voice channel!")
return return