Return the main timeline for events which are not part of a thread. (#14140)

Fixes a bug where threaded receipts could not be sent for the
main timeline.
This commit is contained in:
Patrick Cloke 2022-10-12 12:15:52 -04:00 committed by GitHub
parent e4e55f8eef
commit 87099b6ea5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 6 deletions

View file

@ -236,7 +236,7 @@ class BulkPushRuleEvaluator:
else:
# Since the event has not yet been persisted we check whether
# the parent is part of a thread.
thread_id = await self.store.get_thread_id(relation.parent_id) or "main"
thread_id = await self.store.get_thread_id(relation.parent_id)
# It's possible that old room versions have non-integer power levels (floats or
# strings). Workaround this by explicitly converting to int.