From 8f0c8115694d909606bfd5ae77383c9f79b7148b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E5=BC=BA?= <1206709430@qq.com> Date: Sat, 14 May 2022 14:16:46 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8A=9F=E8=83=BD=E5=8F=98=E5=8C=96:=20celery?= =?UTF-8?q?=20=E9=85=8D=E7=BD=AEbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/application/celery.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/application/celery.py b/backend/application/celery.py index c2b938d..42fb1fa 100644 --- a/backend/application/celery.py +++ b/backend/application/celery.py @@ -5,7 +5,7 @@ os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'application.settings') from django.conf import settings from celery import platforms -if getattr(settings, 'REGISTER_PLUGINS', {}).get('dvadmin_tenant', None): +if 'dvadmin_tenant' in settings.REGISTER_PLUGINS: from tenant_schemas_celery.app import CeleryApp as TenantAwareCeleryApp app = TenantAwareCeleryApp() else: