summary refs log tree commit diff
path: root/synapse/storage/_base.py
diff options
context:
space:
mode:
Diffstat (limited to 'synapse/storage/_base.py')
-rw-r--r--synapse/storage/_base.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/storage/_base.py b/synapse/storage/_base.py
index 476c84c621..470f7881ab 100644
--- a/synapse/storage/_base.py
+++ b/synapse/storage/_base.py
@@ -608,7 +608,7 @@ class SQLBaseStore(object):
         }
 
         if keyvalues:
-            sql += "WHERE %s" % " AND ".join("%s = ?" % k for k in keyvalues.iterkeys())
+            sql += " WHERE %s" % " AND ".join("%s = ?" % k for k in keyvalues.iterkeys())
             txn.execute(sql, keyvalues.values())
         else:
             txn.execute(sql)