Hey team, Could I get a review on this PR: <https:...
# infisical-contributing
s
Hey team, Could I get a review on this PR: https://github.com/Infisical/infisical/pull/5719 I’ve been exploring org/sub-org/group flows to better understand the product, and I came across this inconsistency: • On the individual group page, Edit Group doesn’t preselect the current role, while the Access Management flow does. • It’s important to fix because an empty role dropdown during edit can lead to accidental wrong updates and makes behavior inconsistent across entry points.
Issue link: https://github.com/Infisical/infisical/issues/5726 Sharing fuller context for this PR in case helpful for review: I’ve been actively exploring org/sub-org/group flows to get deeper familiarity with the product behavior end-to-end, and while doing that I found an inconsistency in group edit UX. What I observed: • On individual group page (
/organizations/:orgId/groups/:groupId
), when opening Edit Group, the role dropdown was not preselected. • On Access Management (
/organizations/:orgId/access-management
, Groups tab), editing the same group preselected role correctly. Why this matters: • This creates inconsistent behavior across two entry points for the same action. • More importantly, seeing an empty/unset role in an edit form can cause accidental incorrect updates, especially when users expect “current value” to be shown before making changes. Root cause (high level): • The group-details edit path was passing role data in a shape that didn’t always resolve correctly in modal defaulting logic (notably for custom-role scenarios). • Access Management path had a payload/modal flow that resolved role correctly. What this PR changes: • Aligns group-details edit payload + modal default resolution with the working behavior pattern. • Ensures existing role is resolved and prefilled reliably (including custom-role cases via
customRoleSlug
resolution). • Keeps behavior-only scope; no backend/API logic changes and no visual changes. Validation done: 1. Open group details page and trigger edit from both: - Options menu - Details card edit icon 2. Confirm role is preselected in both. 3. Re-check Access Management Groups edit flow remains unchanged/working.