Fix Directory: Removing a user from all groups does not sync the changes correctly

This commit is contained in:
Maurus Decimus
2026-07-05 10:12:02 +02:00
parent 03c55362ef
commit fb6f0c65a2
2 changed files with 6 additions and 6 deletions

View File

@@ -21,6 +21,7 @@ If you are upgrading from v0.16.x, replace the binary (or run `docker pull`). If
- Registry: Changing the type of an existing account from `user` to `group` panics.
- Masked emails: Return `UnknownRecipient` only for disabled or expired masked emails.
- IDN: `sanitize_email` rejects valid Punycode domains.
- Directory: Removing a user from all groups does not sync the changes correctly.
## [0.16.11] - 2026-06-25

View File

@@ -103,12 +103,11 @@ impl Server {
.into(),
);
}
if !member_group_ids.is_empty()
&& ((updated_account.member_group_ids.len() != member_group_ids.len())
|| !updated_account
.member_group_ids
.iter()
.all(|id| member_group_ids.contains(id)))
if updated_account.member_group_ids.len() != member_group_ids.len()
|| !updated_account
.member_group_ids
.iter()
.all(|id| member_group_ids.contains(id))
{
updated_account.member_group_ids = member_group_ids.into();
has_changes = true;