summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
Diffstat (limited to 'synapse')
-rw-r--r--synapse/handlers/room.py4
-rw-r--r--synapse/push/push_rule_evaluator.py5
-rw-r--r--synapse/replication/resource.py2
-rw-r--r--synapse/storage/events.py3
4 files changed, 9 insertions, 5 deletions
diff --git a/synapse/handlers/room.py b/synapse/handlers/room.py
index 71f7ab3d22..a230dc37f2 100644
--- a/synapse/handlers/room.py
+++ b/synapse/handlers/room.py
@@ -536,7 +536,9 @@ class RoomMemberHandler(BaseHandler):
 
             if not is_host_in_room:
                 # perhaps we've been invited
-                inviter = self.get_inviter(target_user.to_string(), context.current_state)
+                inviter = self.get_inviter(
+                    target_user.to_string(), context.current_state
+                )
                 if not inviter:
                     raise SynapseError(404, "Not a known room")
 
diff --git a/synapse/push/push_rule_evaluator.py b/synapse/push/push_rule_evaluator.py
index 51f73a5b78..c3c2877629 100644
--- a/synapse/push/push_rule_evaluator.py
+++ b/synapse/push/push_rule_evaluator.py
@@ -133,8 +133,9 @@ class PushRuleEvaluator:
             enabled = self.enabled_map.get(r['rule_id'], None)
             if enabled is not None and not enabled:
                 continue
-
-            if not r.get("enabled", True):
+            elif enabled is None and not r.get("enabled", True):
+                # if no override, check enabled on the rule itself
+                # (may have come from a base rule)
                 continue
 
             conditions = r['conditions']
diff --git a/synapse/replication/resource.py b/synapse/replication/resource.py
index 69afcb03d2..c51a6fa103 100644
--- a/synapse/replication/resource.py
+++ b/synapse/replication/resource.py
@@ -77,7 +77,7 @@ class ReplicationResource(Resource):
     The response is a JSON object with keys for each stream with updates. Under
     each key is a JSON object with:
 
-    * "postion": The current position of the stream.
+    * "position": The current position of the stream.
     * "field_names": The names of the fields in each row.
     * "rows": The updates as an array of arrays.
 
diff --git a/synapse/storage/events.py b/synapse/storage/events.py
index b7ad045e41..dc3e994de9 100644
--- a/synapse/storage/events.py
+++ b/synapse/storage/events.py
@@ -1161,7 +1161,8 @@ class EventsStore(SQLBaseStore):
                 forward_ex_outliers = []
 
             sql = (
-                "SELECT -e.stream_ordering, ej.internal_metadata, ej.json"
+                "SELECT -e.stream_ordering, ej.internal_metadata, ej.json,"
+                " eg.state_group"
                 " FROM events as e"
                 " JOIN event_json as ej"
                 " ON e.event_id = ej.event_id AND e.room_id = ej.room_id"