mirror of
https://github.com/RYGhub/royalnet.git
synced 2024-11-27 13:34:28 +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
|
self.inactivity_timer -= 1
|
||||||
continue
|
continue
|
||||||
for voice_client in self.voice_clients:
|
for voice_client in self.voice_clients:
|
||||||
if voice_client.is_connected():
|
try:
|
||||||
logger.info("Disconnecting due to inactivity.")
|
logger.info("Disconnecting due to inactivity.")
|
||||||
await voice_client.disconnect()
|
await voice_client.disconnect()
|
||||||
await self.change_presence(status=discord.Status.online, activity=None)
|
await self.change_presence(status=discord.Status.online, activity=None)
|
||||||
await self.main_channel.send("💤 Mi sono disconnesso dalla cv per inattività.")
|
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):
|
async def create_activityreport(self):
|
||||||
logger.debug("Fetching Discord users...")
|
logger.debug("Fetching Discord users...")
|
||||||
|
|
Loading…
Reference in a new issue