Skip to content

Commit f384d1c

Browse files
committed
Fixed the pub/sub logic accidentally stringing the first value of a multi/exec response
1 parent 6f1acb0 commit f384d1c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -648,7 +648,7 @@ RedisClient.prototype.return_reply = function (reply) {
648648
// If the "reply" here is actually a message received asynchronously due to a
649649
// pubsub subscription, don't pop the command queue as we'll only be consuming
650650
// the head command prematurely.
651-
if (Array.isArray(reply) && reply.length > 0 && reply[0]) {
651+
if (this.pub_sub_mode && Array.isArray(reply) && reply.length > 0 && reply[0]) {
652652
type = reply[0].toString();
653653
}
654654

0 commit comments

Comments
 (0)