diff options
author | Patrick Cloke <clokep@users.noreply.github.com> | 2020-06-22 07:18:00 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-22 07:18:00 -0400 |
commit | e060bf44625da4aa0a61fc792c3ef9af8ad05769 (patch) | |
tree | 54fa2035f869a10cb377bf49cbf2318933ca0568 /synapse/handlers/message.py | |
parent | Speed up state res v2 across large state differences. (#7725) (diff) | |
download | synapse-e060bf44625da4aa0a61fc792c3ef9af8ad05769.tar.xz |
Convert directory handler to async/await (#7727)
Diffstat (limited to 'synapse/handlers/message.py')
-rw-r--r-- | synapse/handlers/message.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/synapse/handlers/message.py b/synapse/handlers/message.py index 200127d291..665ad19b5d 100644 --- a/synapse/handlers/message.py +++ b/synapse/handlers/message.py @@ -879,7 +879,9 @@ class EventCreationHandler(object): """ room_alias = RoomAlias.from_string(room_alias_str) try: - mapping = yield directory_handler.get_association(room_alias) + mapping = yield defer.ensureDeferred( + directory_handler.get_association(room_alias) + ) except SynapseError as e: # Turn M_NOT_FOUND errors into M_BAD_ALIAS errors. if e.errcode == Codes.NOT_FOUND: |