mirror of
https://github.com/nextcloud/server.git
synced 2026-06-09 00:32:29 -04:00
Merge pull request #9732 from owncloud/fix-9716
do not show selected groups twice after user creation
This commit is contained in:
commit
252c239a2a
1 changed files with 3 additions and 1 deletions
|
|
@ -654,9 +654,11 @@ $(document).ready(function () {
|
|||
} else {
|
||||
if (result.data.groups) {
|
||||
var addedGroups = result.data.groups;
|
||||
UserList.availableGroups = $.unique($.merge(UserList.availableGroups, addedGroups));
|
||||
for (var i in result.data.groups) {
|
||||
var gid = result.data.groups[i];
|
||||
if(UserList.availableGroups.indexOf(gid) === -1) {
|
||||
UserList.availableGroups.push(gid);
|
||||
}
|
||||
$li = GroupList.getGroupLI(gid);
|
||||
userCount = GroupList.getUserCount($li);
|
||||
GroupList.setUserCount($li, userCount + 1);
|
||||
|
|
|
|||
Loading…
Reference in a new issue