Skip to content

Commit 2de175b

Browse files
merge master
1 parent 68c6323 commit 2de175b

File tree

2 files changed

+0
-5
lines changed

2 files changed

+0
-5
lines changed

redis/commands/core.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2520,10 +2520,6 @@ def zrange(self, name, start, end, desc=False, withscores=False,
25202520
``offset`` and ``num`` are specified, then return a slice of the range.
25212521
Can't be provided when using ``bylex``.
25222522
"""
2523-
# Supports old implementation: need to support ``desc`` also for version < 6.2.0
2524-
if not byscore and not bylex and (offset is None and num is None) and desc:
2525-
return self.zrevrange(name, start, end, withscores,
2526-
score_cast_func)
25272523
return self._zrange('ZRANGE', None, name, start, end, desc, byscore,
25282524
bylex, withscores, score_cast_func, offset, num)
25292525

tests/test_commands.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1867,7 +1867,6 @@ def test_zrange(self, r):
18671867
assert r.zrange('a', 0, 1) == [b'a1', b'a2']
18681868
assert r.zrange('a', 1, 2) == [b'a2', b'a3']
18691869
assert r.zrange('a', 0, 2) == [b'a1', b'a2', b'a3']
1870-
assert r.zrange('a', 0, 2, desc=True) == [b'a3', b'a2', b'a1']
18711870

18721871
# withscores
18731872
assert r.zrange('a', 0, 1, withscores=True) == \

0 commit comments

Comments
 (0)