Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Fix UndefinedColumn: column "key_json" does not exist errors when h…
Browse files Browse the repository at this point in the history
…andling users with more than 50 non-E2E devices (#14580)
  • Loading branch information
David Robertson authored Nov 29, 2022
1 parent 8c5b8e6 commit e860316
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions synapse/storage/databases/main/devices.py
Original file line number Diff line number Diff line change
Expand Up @@ -1559,6 +1559,7 @@ async def check_too_many_devices_for_user(self, user_id: str) -> Collection[str]
# that ensures we keep at most 50 devices.
sql = """
SELECT last_seen FROM devices
LEFT JOIN e2e_device_keys_json USING (user_id, device_id)
WHERE
user_id = ?
AND NOT hidden
Expand Down

0 comments on commit e860316

Please sign in to comment.