diff options
author | aachurin <aachurin@gmail.com> | 2019-03-16 18:22:29 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-16 18:22:29 +0300 |
commit | 7fa64685d37e953502680f2c5e6f4fde297a351a (patch) | |
tree | a7f5d7a04dc0169e286986ee743f9fb2019fb3ce | |
parent | f87d40c64849acfbb9656aeafbeb6c7e4a264e23 (diff) | |
download | redis-py-7fa64685d37e953502680f2c5e6f4fde297a351a.tar.gz |
Update client.py
Fix for https://github.com/andymccurdy/redis-py/issues/1135
-rwxr-xr-x | redis/client.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/redis/client.py b/redis/client.py index 24120d2..7a3a7c8 100755 --- a/redis/client.py +++ b/redis/client.py @@ -275,9 +275,11 @@ def parse_xclaim(response, **options): def parse_xinfo_stream(response): data = pairs_to_dict(response, decode_keys=True) first = data['first-entry'] - data['first-entry'] = (first[0], pairs_to_dict(first[1])) + if first is not None: + data['first-entry'] = (first[0], pairs_to_dict(first[1])) last = data['last-entry'] - data['last-entry'] = (last[0], pairs_to_dict(last[1])) + if last is not None: + data['last-entry'] = (last[0], pairs_to_dict(last[1])) return data |