summary refs log tree commit diff
path: root/synapse/handlers/message.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2014-12-15 17:01:12 +0000
committerErik Johnston <erik@matrix.org>2014-12-15 17:01:12 +0000
commitcf6e5f1dbf3cecf693e45f293535e71ee31801ed (patch)
treeea0f29cfd9168f1d1a7030ca66372cd42df64eb8 /synapse/handlers/message.py
parentRemove unused functions (diff)
downloadsynapse-cf6e5f1dbf3cecf693e45f293535e71ee31801ed.tar.xz
Rename MessageHandler.handle_event. Add a few comments.
Diffstat (limited to 'synapse/handlers/message.py')
-rw-r--r--synapse/handlers/message.py14
1 files changed, 13 insertions, 1 deletions
diff --git a/synapse/handlers/message.py b/synapse/handlers/message.py
index 4fa4ffea25..1eed38c6d1 100644
--- a/synapse/handlers/message.py
+++ b/synapse/handlers/message.py
@@ -138,7 +138,19 @@ class MessageHandler(BaseHandler):
         defer.returnValue(chunk)
 
     @defer.inlineCallbacks
-    def handle_event(self, event_dict):
+    def create_and_send_event(self, event_dict):
+        """ Given a dict from a client, create and handle a new event.
+
+        Creates an FrozenEvent object, filling out auth_events, prev_events,
+        etc.
+
+        Adds display names to Join membership events.
+
+        Persists and notifies local clients and federation.
+
+        Args:
+            event_dict (dict): An entire event
+        """
         builder = self.event_builder_factory.new(event_dict)
 
         self.validator.validate_new(builder)