mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-08 08:49:52 +03:00
text changes and formatting
This commit is contained in:
@@ -121,9 +121,9 @@ void WebAPIService::parse(AsyncWebServerRequest * request, JsonObject & input) {
|
||||
if (return_code != CommandRet::OK) {
|
||||
char error[100];
|
||||
if (output.size()) {
|
||||
snprintf(error, sizeof(error), "Call failed with error: %s (%s)", (const char *)output["message"], Command::return_code_string(return_code).c_str());
|
||||
snprintf(error, sizeof(error), "API failed with error: %s (%s)", (const char *)output["message"], Command::return_code_string(return_code).c_str());
|
||||
} else {
|
||||
snprintf(error, sizeof(error), "Call failed with error code (%s)", Command::return_code_string(return_code).c_str());
|
||||
snprintf(error, sizeof(error), "API failed with error code (%s)", Command::return_code_string(return_code).c_str());
|
||||
}
|
||||
emsesp::EMSESP::logger().err(error);
|
||||
api_fails_++;
|
||||
|
||||
@@ -219,8 +219,8 @@ bool WebEntityService::get_value_info(JsonObject & output, const char * cmd) {
|
||||
return false;
|
||||
}
|
||||
if (Helpers::toLower(cmd) == "commands") {
|
||||
output["info"] = "lists all values";
|
||||
output["commands"] = "lists all commands";
|
||||
output["info"] = "list all values";
|
||||
output["commands"] = "list all commands";
|
||||
for (const auto & entity : *entityItems) {
|
||||
output[entity.name] = "custom entitiy";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user