objid property is obsolete, use obj instead

This commit is contained in:
fvanroie 2021-04-13 04:45:00 +02:00
parent 83b54eeec6
commit 88d1f69069
2 changed files with 4 additions and 4 deletions

View File

@ -803,9 +803,9 @@ void dispatch_moodlight(const char* topic, const char* payload)
if(!json[F("state")].isNull())
moodlight.power = Utilities::is_true(json[F("state")].as<std::string>().c_str());
if(!json[F("r")].isNull()) moodlight.r = json[F("r")].as<uint8_t>();
if(!json[F("g")].isNull()) moodlight.g = json[F("g")].as<uint8_t>();
if(!json[F("b")].isNull()) moodlight.b = json[F("b")].as<uint8_t>();
if(!json["r"].isNull()) moodlight.r = json["r"].as<uint8_t>();
if(!json["g"].isNull()) moodlight.g = json["g"].as<uint8_t>();
if(!json["b"].isNull()) moodlight.b = json["b"].as<uint8_t>();
if(!json[F("color")].isNull()) {
if(!json[F("color")]["r"].isNull()) {

View File

@ -386,7 +386,7 @@ void hasp_new_object(const JsonObject& config, uint8_t& saved_page_id)
config.remove(FPSTR(FP_OBJ));
}
} else {
LOG_WARNING(TAG_HASP, F("objid property is obsolete, use obj instead"));
LOG_WARNING(TAG_HASP, F("objid property is obsolete, use obj instead")); // TODO: obsolete objid
sdbm = config[FPSTR(FP_OBJID)].as<uint8_t>();
config.remove(FPSTR(FP_OBJID));
}