mirror of
https://github.com/RYGhub/royalnet.git
synced 2024-11-23 19:44:20 +00:00
Try to find out the cause of the ghost bot appearences
This commit is contained in:
parent
f6d8b14bba
commit
73073ad858
1 changed files with 3 additions and 1 deletions
|
@ -802,11 +802,13 @@ class RoyalDiscordBot(discord.Client):
|
|||
self.inactivity_timer -= 1
|
||||
continue
|
||||
for voice_client in self.voice_clients:
|
||||
if voice_client.is_connected():
|
||||
try:
|
||||
logger.info("Disconnecting due to inactivity.")
|
||||
await voice_client.disconnect()
|
||||
await self.change_presence(status=discord.Status.online, activity=None)
|
||||
await self.main_channel.send("💤 Mi sono disconnesso dalla cv per inattività.")
|
||||
except Exception:
|
||||
raise Exception("Ciao! Sono un errore intenzionale di Steffo per testare il countdown inattività!")
|
||||
|
||||
async def create_activityreport(self):
|
||||
logger.debug("Fetching Discord users...")
|
||||
|
|
Loading…
Reference in a new issue