From 6c7ad3d8e7b1c5fa721798415cf0714a428f7998 Mon Sep 17 00:00:00 2001 From: Stefano Pigozzi Date: Sun, 4 Sep 2016 20:35:45 +0200 Subject: [PATCH] waaaaaaaaaaaaaaaaaaaaaa --- bot.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/bot.py b/bot.py index e0354ee5..285d3cbf 100644 --- a/bot.py +++ b/bot.py @@ -292,11 +292,11 @@ def automah(): def cv(): + print("@" + username + ": /roll") # Elenco di tutte le persone online su Discord tosend = "*Su Discord ora:*\n" r = discord.getwidgetdata("176353500710699008") musicstatus = str() - musicchannel = str() for member in r['members']: m = dict() if 'bot' not in member or not member['bot']: @@ -331,10 +331,9 @@ def cv(): # Controlla se l'utente รจ royal music elif member['id'] == "176358898851250176": if 'game' in member: - musicchannel = discord.getchannelname(r, member['channel_id']) - musicstatus = "{emoji} *{channelname}* {songname}\n".format(emoji="\U0001F3B5", - channelname=musicchannel, - songname=member['game']['name']) + musicstatus = "{emoji} *{channelname}* {songname}\n" \ + .format(emoji="\U0001F3B5", channelname=discord.getchannelname(r, member['channel_id']), + songname=member['game']['name']) if musicstatus != "": tosend += musicstatus telegram.sendmessage(tosend, sentin, source)