summaryrefslogtreecommitdiff
path: root/redis/client.py
diff options
context:
space:
mode:
Diffstat (limited to 'redis/client.py')
-rw-r--r--redis/client.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/redis/client.py b/redis/client.py
index 908c933..d0f7516 100644
--- a/redis/client.py
+++ b/redis/client.py
@@ -181,7 +181,6 @@ class Redis(threading.local):
string_keys_to_dict('ZRANGE ZRANGEBYSCORE ZREVRANGE', zset_score_pairs),
{
'BGSAVE': lambda r: r == 'Background saving started',
- 'HSET': lambda r: True,
'INFO': parse_info,
'LASTSAVE': timestamp_to_datetime,
'PING': lambda r: r == 'PONG',
@@ -874,7 +873,10 @@ class Redis(threading.local):
return self.format_bulk('HGET', name, key)
def hset(self, name, key, value):
- "Set ``key`` to ``value`` within hash ``name``"
+ """
+ Set ``key`` to ``value`` within hash ``name``
+ Returns 1 if HSET created a new field, otherwise 0
+ """
return self.format_multi_bulk('HSET', name, key, value)