json type

This commit is contained in:
MichaelDvP
2024-09-20 15:59:45 +02:00
parent c315463692
commit 483a138f9d
2 changed files with 2 additions and 2 deletions

View File

@@ -553,7 +553,7 @@ static void setup_commands(std::shared_ptr<Commands> & commands) {
if (return_code == CommandRet::OK) { if (return_code == CommandRet::OK) {
if (json.size()) { if (json.size()) {
if (json["api_data"].is<std::string>()) { if (json["api_data"].is<std::string>()) {
String data = json["api_data"]; std::string data = json["api_data"];
shell.println(data.c_str()); shell.println(data.c_str());
return; return;
} }

View File

@@ -1684,7 +1684,7 @@ bool EMSdevice::generate_values(JsonObject output, const int8_t tag_filter, cons
} }
// do not overwrite // do not overwrite
if (json[name].is<const char *>()) { if (json[name].is<JsonVariantConst>()) {
#if defined(EMSESP_DEBUG) #if defined(EMSESP_DEBUG)
EMSESP::logger().debug("warning: double json key: %s", name); EMSESP::logger().debug("warning: double json key: %s", name);
#endif #endif