dont reinit or recreate things made in on_ready

This commit is contained in:
Adriene Hutchins 2020-03-02 16:22:28 -05:00
parent 7e09232e56
commit 8adc005f50
1 changed files with 6 additions and 3 deletions

View File

@ -96,14 +96,17 @@ class Bot(commands.Bot):
"""Initializes the main portion of the bot once it has connected."""
# Prerequisites
self.request = aiohttp.ClientSession()
self.appinfo = await self.application_info()
if not hasattr(self, 'request'):
self.request = aiohttp.ClientSession()
if not hasattr(self, 'appinfo'):
self.appinfo = await self.application_info()
if self.description == '':
self.description = self.appinfo.description
# NOTE Extension Entry Point
# Loads core, which loads all other extensions
self._init_extensions()
if self.extensions_list == []:
self._init_extensions()
# Logging
msg = "CONNECTED!\n"