From 3fcffe7d0496a0cb0cceb7b9933947ffdc9692eb Mon Sep 17 00:00:00 2001 From: antirez Date: Thu, 30 Apr 2020 13:42:25 +0200 Subject: [PATCH] redis-cli: fix hints with subcommands. --- src/redis-cli.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/redis-cli.c b/src/redis-cli.c index ec0f58f5f..880f3d70a 100644 --- a/src/redis-cli.c +++ b/src/redis-cli.c @@ -699,7 +699,8 @@ static char *hintsCallback(const char *buf, int *color, int *bold) { for (i = 0; i < helpEntriesLen; i++) { if (!(helpEntries[i].type & CLI_HELP_COMMAND)) continue; - if (strcasecmp(argv[0],helpEntries[i].full) == 0) + if (strcasecmp(argv[0],helpEntries[i].full) == 0 || + strcasecmp(buf,helpEntries[i].full) == 0) { *color = 90; *bold = 0;