summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
Diffstat (limited to 'synapse')
-rw-r--r--synapse/storage/search.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/storage/search.py b/synapse/storage/search.py
index 7a30ce25eb..1b987161e2 100644
--- a/synapse/storage/search.py
+++ b/synapse/storage/search.py
@@ -54,7 +54,7 @@ class SearchStore(SQLBaseStore):
         for clause in clauses:
             sql += " AND " + clause
 
-        sql += " ORDER BY rank DESC"
+        sql += " ORDER BY rank DESC LIMIT 500"
 
         results = yield self._execute(
             "search_msgs", self.cursor_to_dict, sql, *([search_term] + args)