mirror of
https://github.com/fosrl/pangolin.git
synced 2026-03-29 09:55:45 +00:00
fix no admin user in roles dropdown
This commit is contained in:
@@ -126,16 +126,10 @@ export default function AccessControlsPage() {
|
||||
form.setValue("autoProvisioned", user.autoProvisioned || false);
|
||||
}, []);
|
||||
|
||||
const allRoleOptions = useMemo(
|
||||
() =>
|
||||
roles
|
||||
.map((role) => ({
|
||||
id: role.roleId.toString(),
|
||||
text: role.name
|
||||
}))
|
||||
.filter((role) => role.text !== "Admin"),
|
||||
[roles]
|
||||
);
|
||||
const allRoleOptions = roles.map((role) => ({
|
||||
id: role.roleId.toString(),
|
||||
text: role.name
|
||||
}));
|
||||
|
||||
function setRoleTags(updater: Tag[] | ((prev: Tag[]) => Tag[])) {
|
||||
const prev = form.getValues("roles");
|
||||
|
||||
Reference in New Issue
Block a user