From 8d52302c7e61f9261c23d99e4f3403b24d314f3d Mon Sep 17 00:00:00 2001 From: Kseninia Mikhaylova Date: Tue, 16 Jul 2024 17:16:19 +0300 Subject: [PATCH] not main thread --- back/tgbot/apps.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/back/tgbot/apps.py b/back/tgbot/apps.py index 9090f06..a6e9946 100644 --- a/back/tgbot/apps.py +++ b/back/tgbot/apps.py @@ -77,7 +77,7 @@ class TgbotConfig(AppConfig): default_auto_field = "django.db.models.BigAutoField" name = "tgbot" def ready(self): - if not TgBotUpdater.is_run and os.environ.get("RUN_MAIN", None) == "true": + if not TgBotUpdater.is_run and os.environ.get("RUN_MAIN", None) != "true": threading.Thread( target=(TgBotUpdater().run_func), name="tg_updater_thread",