Return the thread ID properly down sync. (#14159)
A receipt's thread ID, if one exists, should be added to the body of a receipt.pull/14163/head
parent
87099b6ea5
commit
e6e876b9b1
|
@ -0,0 +1 @@
|
||||||
|
Support for thread-specific notifications & receipts ([MSC3771](https://github.com/matrix-org/matrix-spec-proposals/pull/3771) and [MSC3773](https://github.com/matrix-org/matrix-spec-proposals/pull/3773)).
|
|
@ -416,6 +416,8 @@ class ReceiptsWorkerStore(SQLBaseStore):
|
||||||
# {"$foo:bar": { "read": { "@user:host": <receipt> }, .. }, .. }
|
# {"$foo:bar": { "read": { "@user:host": <receipt> }, .. }, .. }
|
||||||
event_entry = room_event["content"].setdefault(row["event_id"], {})
|
event_entry = room_event["content"].setdefault(row["event_id"], {})
|
||||||
receipt_type = event_entry.setdefault(row["receipt_type"], {})
|
receipt_type = event_entry.setdefault(row["receipt_type"], {})
|
||||||
|
if row["thread_id"]:
|
||||||
|
receipt_type[row["user_id"]]["thread_id"] = row["thread_id"]
|
||||||
|
|
||||||
receipt_type[row["user_id"]] = db_to_json(row["data"])
|
receipt_type[row["user_id"]] = db_to_json(row["data"])
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue