mirror of
https://github.com/dragonflydb/dragonfly.git
synced 2025-05-10 18:05:44 +02:00
fix: command docs (#4229)
Signed-off-by: kostas <kostas@dragonflydb.io>
This commit is contained in:
parent
a4b3724929
commit
872e49b0b8
2 changed files with 6 additions and 1 deletions
|
@ -2450,7 +2450,7 @@ void Service::Command(CmdArgList args, Transaction* tx, SinkReplyBuilder* builde
|
||||||
return builder->SendLong(cmd_cnt);
|
return builder->SendLong(cmd_cnt);
|
||||||
}
|
}
|
||||||
|
|
||||||
const bool sufficient_args = (args.size() == 2);
|
bool sufficient_args = (args.size() == 2);
|
||||||
|
|
||||||
// INFO [cmd]
|
// INFO [cmd]
|
||||||
if (subcmd == "INFO" && sufficient_args) {
|
if (subcmd == "INFO" && sufficient_args) {
|
||||||
|
@ -2466,6 +2466,7 @@ void Service::Command(CmdArgList args, Transaction* tx, SinkReplyBuilder* builde
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sufficient_args = (args.size() == 1);
|
||||||
if (subcmd == "DOCS" && sufficient_args) {
|
if (subcmd == "DOCS" && sufficient_args) {
|
||||||
return builder->SendOk();
|
return builder->SendOk();
|
||||||
}
|
}
|
||||||
|
|
|
@ -545,4 +545,8 @@ TEST_F(ServerFamilyTest, ConfigNormalization) {
|
||||||
RespArray(ElementsAre("replica_priority", "13")));
|
RespArray(ElementsAre("replica_priority", "13")));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
TEST_F(ServerFamilyTest, CommandDocsOk) {
|
||||||
|
EXPECT_THAT(Run({"command", "docs"}), "OK");
|
||||||
|
}
|
||||||
|
|
||||||
} // namespace dfly
|
} // namespace dfly
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue