Set Red._color before login rather than in on_ready (#5627)

This commit is contained in:
jack1142 2022-03-21 17:23:09 +01:00 committed by GitHub
parent 0f299ae195
commit aa55b08a0a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 2 deletions

View File

@ -216,7 +216,6 @@ class Red(
self._uptime = None
self._checked_time_accuracy = None
self._color = discord.Embed.Empty # This is needed or color ends up 0x000000
self._main_dir = bot_dir
self._cog_mgr = CogManager()
@ -1044,6 +1043,7 @@ class Red(
"""
await self._maybe_update_config()
self.description = await self._config.description()
self._color = discord.Colour(await self._config.color())
init_global_checks(self)
init_events(self, self._cli_flags)

View File

@ -188,7 +188,6 @@ def init_events(bot, cli_flags):
if rich_outdated_message:
rich_console.print(rich_outdated_message)
bot._color = discord.Colour(await bot._config.color())
bot._red_ready.set()
if outdated_red_message:
await send_to_owners_with_prefix_replaced(bot, outdated_red_message)