summary refs log tree commit diff
path: root/synapse/handlers/directory.py
diff options
context:
space:
mode:
Diffstat (limited to 'synapse/handlers/directory.py')
-rw-r--r--synapse/handlers/directory.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/synapse/handlers/directory.py b/synapse/handlers/directory.py
index 58e9a91562..000bf5793c 100644
--- a/synapse/handlers/directory.py
+++ b/synapse/handlers/directory.py
@@ -84,6 +84,13 @@ class DirectoryHandler(BaseHandler):
             if result:
                 room_id = result.room_id
                 servers = result.servers
+            else:
+                # Query AS to see if it exists
+                as_handler = self.hs.get_handlers().appservice_handler
+                result = yield as_handler.query_room_alias_exists(room_alias)
+                if result:
+                    room_id = result.room_id
+                    servers = result.servers
         else:
             try:
                 result = yield self.federation.make_query(