|
|
@ -1273,16 +1273,20 @@ class AIX(User):
|
|
|
|
|
|
|
|
|
|
|
|
if self.groups is not None:
|
|
|
|
if self.groups is not None:
|
|
|
|
current_groups = self.user_group_membership()
|
|
|
|
current_groups = self.user_group_membership()
|
|
|
|
|
|
|
|
groups_need_mod = False
|
|
|
|
|
|
|
|
groups = []
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if self.groups == '':
|
|
|
|
|
|
|
|
if current_groups and not self.append:
|
|
|
|
|
|
|
|
groups_need_mod = True
|
|
|
|
|
|
|
|
else:
|
|
|
|
groups = self.get_groups_set()
|
|
|
|
groups = self.get_groups_set()
|
|
|
|
group_diff = set(current_groups).symmetric_difference(groups)
|
|
|
|
group_diff = set(current_groups).symmetric_difference(groups)
|
|
|
|
groups_need_mod = False
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if group_diff:
|
|
|
|
if group_diff:
|
|
|
|
if self.append:
|
|
|
|
if self.append:
|
|
|
|
for g in groups:
|
|
|
|
for g in groups:
|
|
|
|
if g in group_diff:
|
|
|
|
if g in group_diff:
|
|
|
|
groups.extend(current_groups)
|
|
|
|
|
|
|
|
set(groups)
|
|
|
|
|
|
|
|
groups_need_mod = True
|
|
|
|
groups_need_mod = True
|
|
|
|
break
|
|
|
|
break
|
|
|
|
else:
|
|
|
|
else:
|
|
|
|