mirror of
https://git.anonymousland.org/anonymousland/synapse-product.git
synced 2025-05-06 17:04:58 -04:00
Convert misc database code to async (#8087)
This commit is contained in:
parent
7bdf9828d5
commit
894dae74fe
11 changed files with 39 additions and 64 deletions
|
@ -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,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue