Do not add groups to sync results if disabled. (#12408)

This commit is contained in:
Patrick Cloke 2022-04-07 09:29:56 -04:00 committed by GitHub
parent d1cd96ce29
commit 1a90c1e3af
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 11 additions and 10 deletions

View file

@ -1155,8 +1155,9 @@ class SyncHandler:
await self.store.get_e2e_unused_fallback_key_types(user_id, device_id)
)
logger.debug("Fetching group data")
await self._generate_sync_entry_for_groups(sync_result_builder)
if self.hs_config.experimental.groups_enabled:
logger.debug("Fetching group data")
await self._generate_sync_entry_for_groups(sync_result_builder)
num_events = 0