mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 14:56:42 -04:00
Bundle relations of relations into the /relations
result. (#11284)
Per updates to MSC2675 which now states that bundled aggregations should be included from the `/relations` endpoint.
This commit is contained in:
parent
7ff22d6da4
commit
379f2650cf
4 changed files with 130 additions and 6 deletions
|
@ -230,12 +230,9 @@ class RelationPaginationServlet(RestServlet):
|
|||
original_event = await self._event_serializer.serialize_event(
|
||||
event, now, bundle_relations=False
|
||||
)
|
||||
# Similarly, we don't allow relations to be applied to relations, so we
|
||||
# return the original relations without any aggregations on top of them
|
||||
# here.
|
||||
serialized_events = await self._event_serializer.serialize_events(
|
||||
events, now, bundle_relations=False
|
||||
)
|
||||
# The relations returned for the requested event do include their
|
||||
# bundled relations.
|
||||
serialized_events = await self._event_serializer.serialize_events(events, now)
|
||||
|
||||
return_value = pagination_chunk.to_dict()
|
||||
return_value["chunk"] = serialized_events
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue