mirror of
https://github.com/element-hq/synapse.git
synced 2024-12-18 17:10:43 +03:00
Cast bacjup version to int when querying
This commit is contained in:
parent
b0ac23319a
commit
efb77b87d1
1 changed files with 6 additions and 1 deletions
|
@ -219,7 +219,12 @@ class EndToEndRoomKeyStore(SQLBaseStore):
|
|||
if version is None:
|
||||
this_version = self._get_current_version(txn, user_id)
|
||||
else:
|
||||
this_version = version
|
||||
try:
|
||||
this_version = int(version)
|
||||
except ValueError:
|
||||
# Our versions are all ints so if we can't convert it to an integer,
|
||||
# it isn't there.
|
||||
raise StoreError(404, "No row found")
|
||||
|
||||
result = self._simple_select_one_txn(
|
||||
txn,
|
||||
|
|
Loading…
Reference in a new issue