1
Fork 0
mirror of https://github.com/RYGhub/royalnet.git synced 2024-11-23 19:44:20 +00:00

ignore afk in report

This commit is contained in:
Steffo 2018-11-20 00:07:53 +01:00
parent 2b8a4af701
commit 410d6d9e62

View file

@ -609,12 +609,12 @@ class RoyalDiscordBot(discord.Client):
for member in discord_users: for member in discord_users:
if member.bot: if member.bot:
continue continue
if member.voice is not None: if member.voice is not None and member.voice.channel != self.main_guild.afk_channel:
cv_count += 1 cv_count += 1
if member.voice.channel.id not in non_empty_channels: if member.voice.channel.id not in non_empty_channels:
non_empty_channels.append(member.voice.channel.id) non_empty_channels.append(member.voice.channel.id)
if len(member.roles) >= 2: if len(member.roles) >= 2:
if member.voice is not None: if member.voice is not None and member.voice.channel != self.main_guild.afk_channel:
cv_members_count += 1 cv_members_count += 1
if member.status != discord.Status.offline and member.status != discord.Status.idle: if member.status != discord.Status.offline and member.status != discord.Status.idle:
online_members_count += 1 online_members_count += 1