summary refs log tree commit diff
path: root/synapse/state.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2015-02-04 14:06:42 +0000
committerErik Johnston <erik@matrix.org>2015-02-04 14:06:46 +0000
commit650e32d45580ddd13826364291bda6760c014df9 (patch)
tree21098f6310175c946359ebec2bed11894a739fc6 /synapse/state.py
parentBrief comment on why we do some things on every call to persist_event and not... (diff)
downloadsynapse-650e32d45580ddd13826364291bda6760c014df9.tar.xz
Change context.auth_events to what the auth_events would be bases on context.current_state, rather than based on the auth_events from the event.
Diffstat (limited to 'synapse/state.py')
-rw-r--r--synapse/state.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/synapse/state.py b/synapse/state.py
index 6a6fb8aea0..695a5e7ac4 100644
--- a/synapse/state.py
+++ b/synapse/state.py
@@ -103,7 +103,9 @@ class StateHandler(object):
             context.state_group = None
 
             if hasattr(event, "auth_events") and event.auth_events:
-                auth_ids = zip(*event.auth_events)[0]
+                auth_ids = self.hs.get_auth().compute_auth_events(
+                    event, context.current_state
+                )
                 context.auth_events = {
                     k: v
                     for k, v in context.current_state.items()
@@ -149,7 +151,9 @@ class StateHandler(object):
                 event.unsigned["replaces_state"] = replaces.event_id
 
         if hasattr(event, "auth_events") and event.auth_events:
-            auth_ids = zip(*event.auth_events)[0]
+            auth_ids = self.hs.get_auth().compute_auth_events(
+                event, context.current_state
+            )
             context.auth_events = {
                 k: v
                 for k, v in context.current_state.items()