summary refs log tree commit diff
path: root/synapse/handlers
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2019-07-05 14:07:56 +0100
committerErik Johnston <erik@matrix.org>2019-07-05 14:07:56 +0100
commit9ccea16d45416397b37fa407709ff455bca415e3 (patch)
treeb496f39f58849c879a3dcdcc66e2f4996350b43d /synapse/handlers
parentFixup from review comments. (diff)
downloadsynapse-9ccea16d45416397b37fa407709ff455bca415e3.tar.xz
Assume key existence. Update docstrings
Diffstat (limited to 'synapse/handlers')
-rw-r--r--synapse/handlers/admin.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/synapse/handlers/admin.py b/synapse/handlers/admin.py
index 69d2c8c36f..f06914a378 100644
--- a/synapse/handlers/admin.py
+++ b/synapse/handlers/admin.py
@@ -209,9 +209,7 @@ class AdminHandler(BaseHandler):
                     # Now check if this event is an unseen prev event, if so
                     # then we remove this event from the appropriate dicts.
                     for child_id in unseen_to_child_events.pop(event.event_id, []):
-                        event_to_unseen_prevs.get(child_id, set()).discard(
-                            event.event_id
-                        )
+                        event_to_unseen_prevs[child_id].discard(event.event_id)
 
                     written_events.add(event.event_id)