summaryrefslogtreecommitdiff
path: root/redis/client.py
diff options
context:
space:
mode:
authorandy <andy@whiskeymedia.com>2013-05-23 10:35:45 -0400
committerandy <andy@whiskeymedia.com>2013-05-23 10:35:45 -0400
commitb51f22d5b72d33eea4026a4cb0a283d639d8c451 (patch)
tree4e0529014397e1f986421cad5d5ec733881340a7 /redis/client.py
parentb5214ab814b6c35aa8f880ef61c0719b851e60e0 (diff)
downloadredis-py-b51f22d5b72d33eea4026a4cb0a283d639d8c451.tar.gz
use iterators for dict traversal in both python 2 and 3
Diffstat (limited to 'redis/client.py')
-rw-r--r--redis/client.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/redis/client.py b/redis/client.py
index 033fd3d..2aab306 100644
--- a/redis/client.py
+++ b/redis/client.py
@@ -4,7 +4,7 @@ import datetime
import sys
import warnings
import time as mod_time
-from redis._compat import (b, izip, imap, iteritems, dictkeys, dictvalues,
+from redis._compat import (b, izip, imap, iteritems, iterkeys, itervalues,
basestring, long, nativestr, urlparse, bytes)
from redis.connection import ConnectionPool, UnixDomainSocketConnection
from redis.exceptions import (
@@ -1298,7 +1298,7 @@ class StrictRedis(object):
def _zaggregate(self, command, dest, keys, aggregate=None):
pieces = [command, dest, len(keys)]
if isinstance(keys, dict):
- keys, weights = dictkeys(keys), dictvalues(keys)
+ keys, weights = iterkeys(keys), itervalues(keys)
else:
weights = None
pieces.extend(keys)