summary refs log tree commit diff
path: root/synapse/storage/stream.py
diff options
context:
space:
mode:
authorMark Haines <mark.haines@matrix.org>2015-01-29 14:58:00 +0000
committerMark Haines <mark.haines@matrix.org>2015-01-29 14:58:00 +0000
commit396a67a09ad6217cab8010466d4f06ac897ad885 (patch)
treecbe6996b8ad2b5560f17944625daedae8bf09285 /synapse/storage/stream.py
parentUse get_room_events_stream to get changes to the rooms if the number of chang... (diff)
parentMerge changes from develop (diff)
downloadsynapse-396a67a09ad6217cab8010466d4f06ac897ad885.tar.xz
Merge branch 'client_v2_filter' into client_v2_sync
Conflicts:
	synapse/rest/client/v2_alpha/__init__.py
Diffstat (limited to 'synapse/storage/stream.py')
-rw-r--r--synapse/storage/stream.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/synapse/storage/stream.py b/synapse/storage/stream.py
index 93ccfd8c10..2ea5e1a021 100644
--- a/synapse/storage/stream.py
+++ b/synapse/storage/stream.py
@@ -82,10 +82,10 @@ class _StreamToken(namedtuple("_StreamToken", "topological stream")):
     def parse(cls, string):
         try:
             if string[0] == 's':
-                return cls(None, int(string[1:]))
+                return cls(topological=None, stream=int(string[1:]))
             if string[0] == 't':
                 parts = string[1:].split('-', 1)
-                return cls(int(parts[1]), int(parts[0]))
+                return cls(topological=int(parts[0]), stream=int(parts[1]))
         except:
             pass
         raise SynapseError(400, "Invalid token %r" % (string,))
@@ -94,7 +94,7 @@ class _StreamToken(namedtuple("_StreamToken", "topological stream")):
     def parse_stream_token(cls, string):
         try:
             if string[0] == 's':
-                return cls(None, int(string[1:]))
+                return cls(topological=None, stream=int(string[1:]))
         except:
             pass
         raise SynapseError(400, "Invalid token %r" % (string,))