mirror of
https://github.com/zitadel/zitadel.git
synced 2025-06-10 23:38:33 +00:00
fix(permission): sql error in cmd/setup/49/01-permitted_orgs_function.sql (#9465)
# Which Problems Are Solved SQL error in `cmd/setup/49/01-permitted_orgs_function.sql` # How the Problems Are Solved Updating `cmd/setup/49/01-permitted_orgs_function.sql` # Additional Context - Closes https://github.com/zitadel/zitadel/issues/9461 Co-authored-by: Iraq Jaber <IraqJaber@gmail.com>
This commit is contained in:
parent
a82f5805b6
commit
3c57e325f7
@ -43,14 +43,14 @@ BEGIN
|
||||
END;
|
||||
|
||||
-- Return the organizations where permission were granted thru org-level roles
|
||||
SELECT array_agg(org_id) INTO org_ids
|
||||
SELECT array_agg(sub.org_id) INTO org_ids
|
||||
FROM (
|
||||
SELECT DISTINCT om.org_id
|
||||
FROM eventstore.org_members om
|
||||
WHERE om.role = ANY(matched_roles)
|
||||
AND om.instance_id = instanceID
|
||||
AND om.user_id = userId
|
||||
);
|
||||
) AS sub;
|
||||
RETURN;
|
||||
END;
|
||||
$$;
|
||||
|
Loading…
x
Reference in New Issue
Block a user