Use error message from backend when updating member role
What does this MR do and why?
Related to #496741 (closed)
Since !154196 (merged) we no longer display the error message from the API response when updating a member's role. This can be confusing to users because they just get a generic message. This MR fixes this bug.
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
| Before | After |
|---|---|
![]() |
![]() |
How to set up and validate locally
- Follow instructions in https://docs.gitlab.com/ee/development/ee_features.html#simulate-a-saas-instance to create a group with Premium or higher license
- Go to that group -> Members
- Add some members
- Go to that group -> Settings -> General -> Permissions and group features.
- Add an email to
Restrict membership by email domainfield - Go to that group -> Members
- Click on a members role to open the drawer
- Try to change the role
Edited by Peter Hegman

