mirror of
https://git.anonymousland.org/anonymousland/synapse-product.git
synced 2025-01-21 13:51:03 -05:00
loop -> gatherResults
This commit is contained in:
parent
ab78a8926e
commit
e1e9f0c5b2
@ -973,16 +973,20 @@ class SQLBaseStore(object):
|
|||||||
res = yield self._execute("_fetch_events", None, sql, *evs)
|
res = yield self._execute("_fetch_events", None, sql, *evs)
|
||||||
rows.extend(res)
|
rows.extend(res)
|
||||||
|
|
||||||
res = []
|
res = yield defer.gatherResults(
|
||||||
for row in rows:
|
[
|
||||||
e = yield self._get_event_from_row(
|
defer.maybeDeferred(
|
||||||
txn,
|
self._get_event_from_row,
|
||||||
row[0], row[1], row[2],
|
txn,
|
||||||
check_redacted=check_redacted,
|
row[0], row[1], row[2],
|
||||||
get_prev_content=get_prev_content,
|
check_redacted=check_redacted,
|
||||||
rejected_reason=row[3],
|
get_prev_content=get_prev_content,
|
||||||
)
|
rejected_reason=row[3],
|
||||||
res.append(e)
|
)
|
||||||
|
for row in rows
|
||||||
|
],
|
||||||
|
consumeErrors=True,
|
||||||
|
)
|
||||||
|
|
||||||
for e in res:
|
for e in res:
|
||||||
self._get_event_cache.prefill(
|
self._get_event_cache.prefill(
|
||||||
|
Loading…
Reference in New Issue
Block a user