From b0c6b8e5bb4f926b7f42c28967e9f8441ec474fc Mon Sep 17 00:00:00 2001 From: c0de Date: Wed, 26 Oct 2022 23:35:52 -0500 Subject: [PATCH] Create database before starting the client --- GhostBallBot/main.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/GhostBallBot/main.py b/GhostBallBot/main.py index 9be160a..3c34413 100644 --- a/GhostBallBot/main.py +++ b/GhostBallBot/main.py @@ -10,11 +10,11 @@ from discord_client.client import GhostBallClient from database.models import DATABASE, database, create_models if __name__ == "__main__": - client = GhostBallClient(intents=None) - client.run(os.environ.get("discord_token")) - # Set up the database if we haven't already if not os.path.exists(DATABASE): database.connect() create_models() database.close() + + client = GhostBallClient(intents=None) + client.run(os.environ.get("discord_token"))