mirror of https://github.com/nymea/nymea.git
added debug output for unknown units
parent
493b211eec
commit
f4b4e72e3a
|
|
@ -368,6 +368,7 @@ void PluginMetadata::parse(const QJsonObject &jsonObject)
|
|||
stateType.setType(t);
|
||||
QPair<bool, Types::Unit> unitVerification = loadAndVerifyUnit(st.value("unit").toString());
|
||||
if (!unitVerification.first) {
|
||||
m_validationErrors.append("Thing class \"" + thingClass.name() + "\" state type \"" + stateTypeName + "\" has invalid unit: " + st.value("unit").toString());
|
||||
hasError = true;
|
||||
} else {
|
||||
stateType.setUnit(unitVerification.second);
|
||||
|
|
|
|||
Loading…
Reference in New Issue