diff options
author | Neil Johnson <neil@fragile.org.uk> | 2018-04-09 17:21:34 +0100 |
---|---|---|
committer | Neil Johnson <neil@fragile.org.uk> | 2018-04-09 17:21:34 +0100 |
commit | 5e785d4d5b4137dfa596fde99c80ff94faff0a71 (patch) | |
tree | daa6637c3c7db3b8f0fe1957f7719ffabb04e026 /synapse/storage/roommember.py | |
parent | Merge branch 'release-v0.27.0' of https://github.com/matrix-org/synapse into ... (diff) | |
parent | Revert "Merge pull request #3066 from matrix-org/rav/remove_redundant_metrics" (diff) | |
download | synapse-5e785d4d5b4137dfa596fde99c80ff94faff0a71.tar.xz |
Merge branch 'develop' of https://github.com/matrix-org/synapse into release-v0.27.0
Diffstat (limited to 'synapse/storage/roommember.py')
-rw-r--r-- | synapse/storage/roommember.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/synapse/storage/roommember.py b/synapse/storage/roommember.py index d662d1cfc0..6a861943a2 100644 --- a/synapse/storage/roommember.py +++ b/synapse/storage/roommember.py @@ -645,8 +645,9 @@ class RoomMemberStore(RoomMemberWorkerStore): def add_membership_profile_txn(txn): sql = (""" - SELECT stream_ordering, event_id, events.room_id, content + SELECT stream_ordering, event_id, events.room_id, event_json.json FROM events + INNER JOIN event_json USING (event_id) INNER JOIN room_memberships USING (event_id) WHERE ? <= stream_ordering AND stream_ordering < ? AND type = 'm.room.member' @@ -667,7 +668,8 @@ class RoomMemberStore(RoomMemberWorkerStore): event_id = row["event_id"] room_id = row["room_id"] try: - content = json.loads(row["content"]) + event_json = json.loads(row["json"]) + content = event_json['content'] except Exception: continue |