diff options
author | Erik Johnston <erik@matrix.org> | 2017-06-09 13:35:15 +0100 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2017-06-09 13:35:15 +0100 |
commit | efc2b7db95c78f658d3719862702b85d5d9d4a76 (patch) | |
tree | 5d8bc7d5cf13ba1d645f845e6f0e8191906301de /synapse | |
parent | Fix has_any_entity_changed (diff) | |
download | synapse-efc2b7db95c78f658d3719862702b85d5d9d4a76.tar.xz |
Rewrite conditional
Diffstat (limited to 'synapse')
-rw-r--r-- | synapse/util/caches/stream_change_cache.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/util/caches/stream_change_cache.py b/synapse/util/caches/stream_change_cache.py index b723e33641..609625b322 100644 --- a/synapse/util/caches/stream_change_cache.py +++ b/synapse/util/caches/stream_change_cache.py @@ -99,7 +99,7 @@ class StreamChangeCache(object): keys = self._cache.keys() i = keys.bisect_right(stream_pos) - return len(keys[i:]) > 0 + return i < len(keys) else: self.metrics.inc_misses() return True |