summary refs log tree commit diff
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2017-06-09 16:40:52 +0100
committerErik Johnston <erik@matrix.org>2017-06-09 16:40:52 +0100
commit80609743440467a69c4bdcd111c60d84f617d6c4 (patch)
tree423ac506015b9c985a9a9d934463db629fbd829e
parentComments (diff)
downloadsynapse-80609743440467a69c4bdcd111c60d84f617d6c4.tar.xz
Fix replication
Diffstat (limited to '')
-rw-r--r--synapse/replication/slave/storage/events.py2
-rw-r--r--synapse/storage/state.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/synapse/replication/slave/storage/events.py b/synapse/replication/slave/storage/events.py
index 6cd3a843df..f0a367aa9b 100644
--- a/synapse/replication/slave/storage/events.py
+++ b/synapse/replication/slave/storage/events.py
@@ -108,7 +108,7 @@ class SlavedEventStore(BaseSlavedStore):
     get_current_state_ids = (
         StateStore.__dict__["get_current_state_ids"]
     )
-    get_state_group_delta = DataStore.get_state_group_delta.__func__
+    get_state_group_delta = StateStore.__dict__["get_state_group_delta"]
     _get_joined_hosts_cache = RoomMemberStore.__dict__["_get_joined_hosts_cache"]
     has_room_changed_since = DataStore.has_room_changed_since.__func__
 
diff --git a/synapse/storage/state.py b/synapse/storage/state.py
index 24503cd5aa..d1e679719b 100644
--- a/synapse/storage/state.py
+++ b/synapse/storage/state.py
@@ -37,7 +37,7 @@ class _GetStateGroupDelta(namedtuple("_GetStateGroupDelta", ("prev_group", "delt
     __slots__ = []
 
     def __len__(self):
-        return len(self.delta_ids) if self.delta_ids else None
+        return len(self.delta_ids) if self.delta_ids else 0
 
 
 class StateStore(SQLBaseStore):