mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-07 16:29:51 +03:00
json type
This commit is contained in:
@@ -553,7 +553,7 @@ static void setup_commands(std::shared_ptr<Commands> & commands) {
|
||||
if (return_code == CommandRet::OK) {
|
||||
if (json.size()) {
|
||||
if (json["api_data"].is<std::string>()) {
|
||||
String data = json["api_data"];
|
||||
std::string data = json["api_data"];
|
||||
shell.println(data.c_str());
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1684,7 +1684,7 @@ bool EMSdevice::generate_values(JsonObject output, const int8_t tag_filter, cons
|
||||
}
|
||||
|
||||
// do not overwrite
|
||||
if (json[name].is<const char *>()) {
|
||||
if (json[name].is<JsonVariantConst>()) {
|
||||
#if defined(EMSESP_DEBUG)
|
||||
EMSESP::logger().debug("warning: double json key: %s", name);
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user