misc: remove compatibility code with old authentic version (#72025)
This commit is contained in:
parent
e104e5859f
commit
42dbb3787b
|
@ -35,12 +35,7 @@ class AppConfig(django.apps.AppConfig):
|
|||
def post_migrate(self, verbosity=2, interactive=True, using=DEFAULT_DB_ALIAS, **kwargs):
|
||||
# create custom operations
|
||||
from authentic2.a2_rbac.models import Operation
|
||||
|
||||
try:
|
||||
from authentic2.a2_rbac.utils import get_operation
|
||||
except ImportError:
|
||||
# legacy
|
||||
from django_rbac.utils import get_operation
|
||||
from authentic2.a2_rbac.utils import get_operation
|
||||
|
||||
if not router.allow_migrate(using, Operation):
|
||||
return
|
||||
|
|
|
@ -11,16 +11,10 @@ from authentic2.a2_rbac.models import (
|
|||
)
|
||||
from authentic2.a2_rbac.models import OrganizationalUnit as OU
|
||||
from authentic2.a2_rbac.models import Permission, Role
|
||||
from authentic2.a2_rbac.utils import get_operation
|
||||
from django.contrib.auth import get_user_model
|
||||
from django.contrib.contenttypes.models import ContentType
|
||||
|
||||
try:
|
||||
from authentic2.a2_rbac.utils import get_operation
|
||||
except ImportError:
|
||||
# legacy
|
||||
from django_rbac.utils import get_operation
|
||||
|
||||
|
||||
User = get_user_model()
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue