Skip to content

Commit 54b952c

Browse files
refactor: include casbin in installed apps before loading models
1 parent 688bb9f commit 54b952c

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

openedx_authz/apps.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ class OpenedxAuthzConfig(AppConfig):
4545
def ready(self):
4646
"""Initialization layer for the openedx_authz app."""
4747
# Initialize the enforcer to ensure it's ready when the app starts
48-
from openedx_authz.engine.enforcer import AuthzEnforcer
4948
casbin_adapter_app = "casbin_adapter.apps.CasbinAdapterConfig"
5049
if casbin_adapter_app not in settings.INSTALLED_APPS:
5150
settings.INSTALLED_APPS.append(casbin_adapter_app)
51+
from openedx_authz.engine.enforcer import AuthzEnforcer
5252
AuthzEnforcer()

0 commit comments

Comments
 (0)