summary refs log tree commit diff
path: root/synapse/state.py
diff options
context:
space:
mode:
authorErik Johnston <erikj@jki.re>2017-01-20 15:14:05 +0000
committerGitHub <noreply@github.com>2017-01-20 15:14:05 +0000
commit3d9d48fffbf4f99607423533695ea1b8ae3b4edc (patch)
treec2ebee1c2495f6bdc3697184f747807746eebba4 /synapse/state.py
parentMerge pull request #1837 from matrix-org/rav/fix_purge_media_doc (diff)
parentSpelling (diff)
downloadsynapse-3d9d48fffbf4f99607423533695ea1b8ae3b4edc.tar.xz
Merge pull request #1836 from matrix-org/erikj/current_state_fix
Derive current_state_events from state groups
Diffstat (limited to 'synapse/state.py')
-rw-r--r--synapse/state.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/synapse/state.py b/synapse/state.py
index 20aaacf40f..383d32b163 100644
--- a/synapse/state.py
+++ b/synapse/state.py
@@ -429,6 +429,9 @@ def resolve_events(state_sets, state_map_factory):
         dict[(str, str), synapse.events.FrozenEvent] is a map from
         (type, state_key) to event.
     """
+    if len(state_sets) == 1:
+        return state_sets[0]
+
     unconflicted_state, conflicted_state = _seperate(
         state_sets,
     )