mirror of
https://github.com/fluencelabs/redis
synced 2025-06-13 17:21:20 +00:00
Now SORT returns an empty bulk reply if the key does not exist
This commit is contained in:
2
redis.c
2
redis.c
@ -4839,7 +4839,7 @@ static void sortCommand(redisClient *c) {
|
||||
/* Lookup the key to sort. It must be of the right types */
|
||||
sortval = lookupKeyRead(c->db,c->argv[1]);
|
||||
if (sortval == NULL) {
|
||||
addReply(c,shared.nokeyerr);
|
||||
addReply(c,shared.nullmultibulk);
|
||||
return;
|
||||
}
|
||||
if (sortval->type != REDIS_SET && sortval->type != REDIS_LIST &&
|
||||
|
Reference in New Issue
Block a user