Skip to content

Commit 2feef0f

Browse files
committed
fix(NewUserDialog): update group selection to prevent admin group from being assigned as subadmin
Signed-off-by: Arsalan Ul Haq Sohni <[email protected]>
1 parent c38e604 commit 2feef0f

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

apps/settings/src/components/Users/NewUserDialog.vue

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@
9696
:input-label="t('settings', 'Admin of the following groups')"
9797
:placeholder="t('settings', 'Set account as admin for …')"
9898
:disabled="loading.groups || loading.all"
99-
:options="availableGroups"
99+
:options="availableSubAdminGroups"
100100
keep-open
101101
:multiple="true"
102102
label="name"
@@ -231,6 +231,10 @@ export default {
231231
return groups.filter((group) => group.id !== '__nc_internal_recent' && group.id !== 'disabled')
232232
},
233233
234+
availableSubAdminGroups() {
235+
return this.availableGroups.filter(group => group.id !== 'admin')
236+
},
237+
234238
languages() {
235239
return [
236240
{

0 commit comments

Comments
 (0)