mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-06-26 00:30:30 -04:00
Rename get_e2e_device_keys
to better reflect its purpose (#8205)
... and to show that it does something slightly different to `_get_e2e_device_keys_txn`. `include_all_devices` and `include_deleted_devices` were never used (and `include_deleted_devices` was broken, since that would cause `None`s in the result which were not handled in the loop below. Add some typing too.
This commit is contained in:
parent
8027166dd5
commit
45e8f7726f
4 changed files with 14 additions and 19 deletions
|
@ -353,7 +353,7 @@ class E2eKeysHandler(object):
|
|||
# make sure that each queried user appears in the result dict
|
||||
result_dict[user_id] = {}
|
||||
|
||||
results = await self.store.get_e2e_device_keys(local_query)
|
||||
results = await self.store.get_e2e_device_keys_for_cs_api(local_query)
|
||||
|
||||
# Build the result structure
|
||||
for user_id, device_keys in results.items():
|
||||
|
@ -734,7 +734,7 @@ class E2eKeysHandler(object):
|
|||
# fetch our stored devices. This is used to 1. verify
|
||||
# signatures on the master key, and 2. to compare with what
|
||||
# was sent if the device was signed
|
||||
devices = await self.store.get_e2e_device_keys([(user_id, None)])
|
||||
devices = await self.store.get_e2e_device_keys_for_cs_api([(user_id, None)])
|
||||
|
||||
if user_id not in devices:
|
||||
raise NotFoundError("No device keys found")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue