Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
This commit is contained in:
Marc 'risson' Schmitt 2024-01-11 15:25:23 +01:00
parent 1cff8902dd
commit cd92eced13
No known key found for this signature in database
GPG Key ID: 9C3FA22FABF1AA8D
1 changed files with 4 additions and 1 deletions

View File

@ -27,7 +27,10 @@ class AuthentikTenantsConfig(ManagedAppConfig):
verbose_name = "authentik Tenants"
default = True
def ready(self):
post_migrate.connect(reconcile_default_tenant)
super().ready()
def reconcile_default_tenant(self):
"""Make sure default tenant exists, especially after a migration"""
reconcile_default_tenant()
post_migrate.connect(reconcile_default_tenant)