ucsAccounts: Correctly negate MW_ groups prefix check

This commit is contained in:
Adam Goldsmith 2022-06-09 14:57:31 -04:00
parent 855f9b652d
commit 6b7194c15a

View File

@ -110,7 +110,9 @@ async def _main():
if re.match(GROUPS_REGEX, group) is not None and value != ""
]
# 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
try: