Skip to content

Commit

Permalink
addressing comments
Browse files Browse the repository at this point in the history
Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com>
  • Loading branch information
sarthakaggarwal97 committed Nov 20, 2024
1 parent 8b013ed commit fa789e6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/t_string.c
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ void setGenericCommand(client *c,
if (flags & OBJ_SET_IFEQ && found) {
robj *current_value = lookupKeyRead(c->db, key);

if (current_value == NULL || current_value->type != OBJ_STRING || checkType(c, comparison, OBJ_STRING) != 0) {
if (checkType(c, current_value, OBJ_STRING) != 0) {
if (!(flags & OBJ_SET_GET)) {
addReplyError(c, "value(s) must be present or string");
}
Expand Down

0 comments on commit fa789e6

Please sign in to comment.