not main thread
This commit is contained in:
parent
8204f47e72
commit
8d52302c7e
|
@ -77,7 +77,7 @@ class TgbotConfig(AppConfig):
|
||||||
default_auto_field = "django.db.models.BigAutoField"
|
default_auto_field = "django.db.models.BigAutoField"
|
||||||
name = "tgbot"
|
name = "tgbot"
|
||||||
def ready(self):
|
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(
|
threading.Thread(
|
||||||
target=(TgBotUpdater().run_func),
|
target=(TgBotUpdater().run_func),
|
||||||
name="tg_updater_thread",
|
name="tg_updater_thread",
|
||||||
|
|
Loading…
Reference in New Issue