loolwsd: Don't send an empty result in frame
Change-Id: Ia4cf4c6d49be4b65d075c8380994dd7115ba2dc6
This commit is contained in:
parent
f9b86d749d
commit
319dd56598
1 changed files with 5 additions and 2 deletions
|
@ -67,8 +67,11 @@ bool AdminRequestHandler::adminCommandHandler(const std::vector<char>& payload)
|
|||
tokens[0] == "mem_stats" ||
|
||||
tokens[0] == "cpu_stats" )
|
||||
{
|
||||
const std::string responseFrame = tokens[0] + " " + model.query(tokens[0]);
|
||||
sendTextFrame(responseFrame);
|
||||
std::string responseFrame = tokens[0] + " ";
|
||||
const std::string result = model.query(tokens[0]);
|
||||
responseFrame += result;
|
||||
if (result != "")
|
||||
sendTextFrame(responseFrame);
|
||||
}
|
||||
else if (tokens[0] == "subscribe" && tokens.count() > 1)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue