diff options
author | Patrick Cloke <clokep@users.noreply.github.com> | 2022-03-18 13:49:32 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-18 17:49:32 +0000 |
commit | 8fe930c215f69913fbcd96d609ec6950644e4ec4 (patch) | |
tree | f7f61edeecb7ffc496ed4839015c46c9f10951c4 /synapse/rest/client/room.py | |
parent | Only fetch thread participation for events with threads. (#12228) (diff) | |
download | synapse-8fe930c215f69913fbcd96d609ec6950644e4ec4.tar.xz |
Move get_bundled_aggregations to relations handler. (#12237)
The get_bundled_aggregations code is fairly high-level and uses a lot of store methods, we move it into the handler as that seems like a better fit.
Diffstat (limited to 'synapse/rest/client/room.py')
-rw-r--r-- | synapse/rest/client/room.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/rest/client/room.py b/synapse/rest/client/room.py index 8a06ab8c5f..47e152c8cc 100644 --- a/synapse/rest/client/room.py +++ b/synapse/rest/client/room.py @@ -645,6 +645,7 @@ class RoomEventServlet(RestServlet): self._store = hs.get_datastores().main self.event_handler = hs.get_event_handler() self._event_serializer = hs.get_event_client_serializer() + self._relations_handler = hs.get_relations_handler() self.auth = hs.get_auth() async def on_GET( @@ -663,7 +664,7 @@ class RoomEventServlet(RestServlet): if event: # Ensure there are bundled aggregations available. - aggregations = await self._store.get_bundled_aggregations( + aggregations = await self._relations_handler.get_bundled_aggregations( [event], requester.user.to_string() ) |