From bf30f5a73922e5111d6a39da7351e22357213134 Mon Sep 17 00:00:00 2001 From: Itamar Haber Date: Tue, 2 Feb 2016 09:58:19 -0800 Subject: [PATCH] Adds keyspace notifications for lrem --- src/t_list.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/t_list.c b/src/t_list.c index 0008404d..7d5be11a 100644 --- a/src/t_list.c +++ b/src/t_list.c @@ -509,12 +509,17 @@ void lremCommand(client *c) { } listTypeReleaseIterator(li); + if (removed) { + signalModifiedKey(c->db,c->argv[1]); + notifyKeyspaceEvent(NOTIFY_GENERIC,"lrem",c->argv[1],c->db->id); + } + if (listTypeLength(subject) == 0) { dbDelete(c->db,c->argv[1]); + notifyKeyspaceEvent(NOTIFY_GENERIC,"del",c->argv[1],c->db->id); } addReplyLongLong(c,removed); - if (removed) signalModifiedKey(c->db,c->argv[1]); } /* This is the semantic of this command: