feat(api): SAML2 configurable admin privileges
This commit is contained in:
parent
c984ff61fb
commit
bd28ba75ba
1 changed files with 3 additions and 3 deletions
|
|
@ -74,9 +74,9 @@ def process_sso_assertion():
|
|||
return {"errors": [f"role {role_name} not found, please create it in openreplay first"]}
|
||||
|
||||
admin_privileges = user_data.get("adminPrivileges", [])
|
||||
admin_privileges = len(admin_privileges) == 0 \
|
||||
or admin_privileges[0] is None \
|
||||
or admin_privileges[0].lower() == "false"
|
||||
admin_privileges = not (len(admin_privileges) == 0
|
||||
or admin_privileges[0] is None
|
||||
or admin_privileges[0].lower() == "false")
|
||||
|
||||
if existing is None:
|
||||
print("== new user ==")
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue