Skip to content
Merged
Prev Previous commit
Next Next commit
Rule index org allow expansion
  • Loading branch information
Emyrk committed Feb 9, 2023
commit 0ef4b5cb513e365485ee3d829e728e576481ae47
2 changes: 2 additions & 0 deletions coderd/rbac/policy.rego
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,8 @@ default scope_org := 0
scope_org := org_allow([input.scope])

org_allow(roles) := num {
# Rule index on org_owner being set.
input.object.org_owner != ""
allow := { id: num |
id := org_members[_]
set := { x |
Expand Down