summaryrefslogtreecommitdiff
path: root/redis
diff options
context:
space:
mode:
Diffstat (limited to 'redis')
-rwxr-xr-xredis/client.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/redis/client.py b/redis/client.py
index ae4fae2..16ffbb0 100755
--- a/redis/client.py
+++ b/redis/client.py
@@ -1530,6 +1530,8 @@ class PubSub:
with a message handler, the handler is invoked instead of a parsed
message being returned.
"""
+ if response is None:
+ return None
message_type = str_if_bytes(response[0])
if message_type == "pmessage":
message = {