forked from CMS/memberPlumbing
ucsAccounts: Correctly negate MW_
groups prefix check
This commit is contained in:
parent
855f9b652d
commit
6b7194c15a
@ -110,7 +110,9 @@ async def _main():
|
|||||||
if re.match(GROUPS_REGEX, group) is not None and value != ""
|
if re.match(GROUPS_REGEX, group) is not None and value != ""
|
||||||
]
|
]
|
||||||
# groups not from this script
|
# groups not from this script
|
||||||
other_old_groups = [g for g in user.props.groups if g[3:].startswith("MW_")]
|
other_old_groups = [
|
||||||
|
g for g in user.props.groups if not g[3:].startswith("MW_")
|
||||||
|
]
|
||||||
user.props.groups = other_old_groups + new_groups
|
user.props.groups = other_old_groups + new_groups
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
Loading…
Reference in New Issue
Block a user