From a8950e1c540b2a2c57d14089d04e4754a44a1bb3 Mon Sep 17 00:00:00 2001 From: Entarno54 Date: Mon, 12 May 2025 19:08:16 +0700 Subject: [PATCH] Returned the on_ready print and made it send out a message to all log channels --- events/log.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/events/log.py b/events/log.py index db0927f..569308a 100644 --- a/events/log.py +++ b/events/log.py @@ -4,7 +4,7 @@ from nextcord.ext import commands from userinfo import parsedinfo class Logger(commands.Cog): - def __init__(self, bot): + def __init__(self, bot: commands.Bot): self.mod = None self.client = bot @@ -43,5 +43,12 @@ class Logger(commands.Cog): channel = ctx.guild.get_channel(guild["log-channel"]) await channel.send(embed=embed) + @commands.Cog.listener() + async def on_ready(self): + print(f"Bot ready as {self.client.user.name}") + for guild in parsedinfo.parsed["guild"]: + if guild["log-channel"] != 1: + await self.client.get_channel(guild["log-channel"]).send("SquogBot instance loaded!") + def setup(bot): bot.add_cog(Logger(bot)) \ No newline at end of file