diff options
author | Patrick Cloke <clokep@users.noreply.github.com> | 2020-08-14 07:24:26 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-14 07:24:26 -0400 |
commit | 894dae74fe8e79911c3c001c8b84620ef3985bf6 (patch) | |
tree | 3ba58a280c6db5eb89e116ef528061592ce8f987 /synapse/storage/databases/main/state.py | |
parent | Remove a space at the start of a changelog entry. (diff) | |
download | synapse-894dae74fe8e79911c3c001c8b84620ef3985bf6.tar.xz |
Convert misc database code to async (#8087)
Diffstat (limited to 'synapse/storage/databases/main/state.py')
-rw-r--r-- | synapse/storage/databases/main/state.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/synapse/storage/databases/main/state.py b/synapse/storage/databases/main/state.py index 96e0378e50..991233a9bc 100644 --- a/synapse/storage/databases/main/state.py +++ b/synapse/storage/databases/main/state.py @@ -273,12 +273,11 @@ class StateGroupWorkerStore(EventsWorkerStore, SQLBaseStore): cached_method_name="_get_state_group_for_event", list_name="event_ids", num_args=1, - inlineCallbacks=True, ) - def _get_state_group_for_events(self, event_ids): + async def _get_state_group_for_events(self, event_ids): """Returns mapping event_id -> state_group """ - rows = yield self.db_pool.simple_select_many_batch( + rows = await self.db_pool.simple_select_many_batch( table="event_to_state_groups", column="event_id", iterable=event_ids, |