Skip to content

Commit

Permalink
Merge pull request #22 from christianstubbe/feature-mongo
Browse files Browse the repository at this point in the history
Fix: Add Missing Init
  • Loading branch information
ehourdebaigt authored Jul 9, 2023
2 parents 27fb0e3 + a2b811e commit 3f536f7
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions toolbox/src/access/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import logging

import casbin
from casbin import Model
from access.adapters.alchemy import adapter
from access.models import pbac

model = Model()
model.load_model_from_text(pbac) # This is not definitive as it could be changed
# based on the request parameters
enforcer = casbin.Enforcer(model, adapter)
enforcer.logger.setLevel(logging.DEBUG)

0 comments on commit 3f536f7

Please sign in to comment.