diff --git a/main.py b/main.py index 675f8ac..8083a70 100644 --- a/main.py +++ b/main.py @@ -46,15 +46,17 @@ with contextlib.suppress(ImportError): def main(): + # Remove if no database is being used + if args.migrate: + migrate_database() + logger.info("Migration finished. Exiting...") + exit() + client = PyroClient( scheduler=scheduler, commands_source=sync.json_read(Path("commands.json")) ) # Conversation(client) - # Remove if no database is being used - if args.migrate: - migrate_database() - try: client.run() except KeyboardInterrupt: