Skip to content

fix: Org admin can remove team members without being on team #11142

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 9, 2025

Conversation

Dschoordsch
Copy link
Contributor

@Dschoordsch Dschoordsch commented Apr 9, 2025

Description

Fixes #11138
The mutation tried to always load the viewer team member which would fail if the org admin wasn't on the team.

Demo

I made a few UI changes to work with long names. I removed the name from the context menus
image
image

And modified the delete and promote modals to wrap the button
image
image

These are extreme cases, so I think it's good enough for now.

Testing scenarios

  • as org admin remove a team member from a team you're not a member of

Final checklist

  • I checked the code review guidelines
  • I have added Metrics Representative as reviewer(s) if my PR invovles metrics/data/analytics related changes
  • I have performed a self-review of my code, the same way I'd do it for any other team member
  • I have tested all cases I listed in the testing scenarios and I haven't found any issues or regressions
  • Whenever I took a non-obvious choice I added a comment explaining why I did it this way
  • I added the label Skip Maintainer Review Indicating the PR only requires reviewer review and can be merged right after it's approved if the PR introduces only minor changes, does not contain any architectural changes or does not introduce any new patterns and I think one review is sufficient'
  • PR title is human readable and could be used in changelog

@github-actions github-actions bot added the size/s label Apr 9, 2025
The mutation tried to always load the viewer team member which would
fail if the org admin wasn't on the team.
@Dschoordsch Dschoordsch force-pushed the fix/11138/orgAdminCanRemoveTeamMember branch from e6eda13 to c3427b7 Compare April 9, 2025 12:19
@Dschoordsch Dschoordsch requested a review from nickoferrall April 9, 2025 12:27
Copy link
Contributor

@nickoferrall nickoferrall left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice fix and UI improvements

@Dschoordsch Dschoordsch merged commit c3ebadb into master Apr 9, 2025
7 checks passed
@Dschoordsch Dschoordsch deleted the fix/11138/orgAdminCanRemoveTeamMember branch April 9, 2025 12:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Org Admin cannot remove user from Team settings view
2 participants