fix(commands/voice): check if message author has a voice channel
This commit is contained in:
parent
2c4a0921a7
commit
bfa1a35922
@ -285,6 +285,6 @@ async def ensure_joined(message):
|
|||||||
|
|
||||||
|
|
||||||
def command_allowed(message):
|
def command_allowed(message):
|
||||||
if not message.guild.voice_client:
|
if not message.author.voice or not message.guild.voice_client:
|
||||||
return False
|
return False
|
||||||
return message.author.voice.channel.id == message.guild.voice_client.channel.id
|
return message.author.voice.channel.id == message.guild.voice_client.channel.id
|
||||||
|
Loading…
x
Reference in New Issue
Block a user