summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
authorMark Haines <mark.haines@matrix.org>2015-10-30 16:38:35 +0000
committerMark Haines <mark.haines@matrix.org>2015-10-30 16:38:35 +0000
commitfb46937413cc0ccbf12063a5743ddf914cd8170a (patch)
treec86dadad61376e608173b33278609c049bd52be8 /synapse
parentInclude tags in v1 room initial sync (diff)
downloadsynapse-fb46937413cc0ccbf12063a5743ddf914cd8170a.tar.xz
Support clients supplying older tokens, fix short poll test
Diffstat (limited to 'synapse')
-rw-r--r--synapse/types.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/types.py b/synapse/types.py
index 8d3a8d88cc..84631d177d 100644
--- a/synapse/types.py
+++ b/synapse/types.py
@@ -112,7 +112,7 @@ class StreamToken(
     def from_string(cls, string):
         try:
             keys = string.split(cls._SEPARATOR)
-            if len(keys) == len(cls._fields) - 1:
+            while len(keys) < len(cls._fields):
                 # i.e. old token from before receipt_key
                 keys.append("0")
             return cls(*keys)