mirror of
https://mau.dev/maunium/synapse.git
synced 2024-12-19 16:23:59 +01:00
Comments
This commit is contained in:
parent
2d5bba151b
commit
8b9f164fff
2 changed files with 6 additions and 2 deletions
|
@ -221,8 +221,9 @@ class EventContext(object):
|
||||||
"""Gets the current state IDs if we have them already cached.
|
"""Gets the current state IDs if we have them already cached.
|
||||||
|
|
||||||
Returns:
|
Returns:
|
||||||
dict[(str, str), str]|None: Returns None if state_group
|
dict[(str, str), str]|None: Returns None if we haven't cached the
|
||||||
is None, which happens when the associated event is an outlier.
|
state or if state_group is None, which happens when the associated
|
||||||
|
event is an outlier.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
return self._current_state_ids
|
return self._current_state_ids
|
||||||
|
|
|
@ -549,6 +549,9 @@ class EventsStore(EventsWorkerStore):
|
||||||
if ctx.state_group in state_groups_map:
|
if ctx.state_group in state_groups_map:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
# We're only interested in pulling out state that has already
|
||||||
|
# been cached in the context. We'll pull stuff out of the DB later
|
||||||
|
# if necessary.
|
||||||
current_state_ids = ctx.get_cached_current_state_ids()
|
current_state_ids = ctx.get_cached_current_state_ids()
|
||||||
if current_state_ids is not None:
|
if current_state_ids is not None:
|
||||||
state_groups_map[ctx.state_group] = current_state_ids
|
state_groups_map[ctx.state_group] = current_state_ids
|
||||||
|
|
Loading…
Reference in a new issue