From 86b4d770cc193d4bfa01e7c9063ad2aa1b6906a7 Mon Sep 17 00:00:00 2001 From: Stefano Pigozzi Date: Tue, 31 Jul 2018 18:22:36 +0200 Subject: [PATCH] Fixato un bug in cui /cv non restituiva nessun messaggio --- discordbot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/discordbot.py b/discordbot.py index 79ce34c2..1a21fa1c 100644 --- a/discordbot.py +++ b/discordbot.py @@ -300,7 +300,7 @@ async def cmd_ping(channel: discord.Channel, author: discord.Member, params: typ async def cmd_cv(channel: discord.Channel, author: discord.Member, params: typing.List[str]): if author is None: await client.send_message(channel, "⚠ Questo comando richiede un autore.") - if author.voice.voice_channel is None: + if author.voice is None or author.voice.voice_channel is None: await client.send_message(channel, "⚠ Non sei in nessun canale!") return global voice_client