File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed
Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -113,7 +113,7 @@ def compute_effective_scopes(role: Role) -> frozenset[str]:
113113 if role .workspace_id and role .workspace_role :
114114 # Org admins/owners already have workspace scopes via their org role
115115 # Regular members need their workspace role scopes
116- if role . org_role not in ( OrgRole . OWNER , OrgRole . ADMIN ) :
116+ if not role . is_org_admin :
117117 scope_set |= PRESET_ROLE_SCOPES .get (role .workspace_role , set ())
118118
119119 # Note: Group-based scopes (from group_assignment table) will be added in PR 4
Original file line number Diff line number Diff line change @@ -264,6 +264,10 @@ async def admin_operation(...):
264264 required = set (scopes )
265265
266266 def check_scopes ():
267+ # Empty required scopes means no restrictions
268+ if not required :
269+ return
270+
267271 user_scopes = ctx_scopes .get ()
268272
269273 # Platform superuser has "*" scope - bypass all checks
You can’t perform that action at this time.
0 commit comments