removed redundant updates of connected status
parent
b1a9b955ef
commit
1992d24cb2
|
|
@ -217,8 +217,11 @@ void IntegrationPluginGaradget::publishReceived(const QString &topic, const QByt
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (topic.endsWith("/status")) {
|
if (topic.endsWith("/status")) {
|
||||||
thing->setStateValue(garadgetConnectedStateTypeId, true);
|
if (thing->stateValue(garadgetConnectedStateTypeId) == false) {
|
||||||
m_garadgetconnect = 1;
|
qCDebug(dcGaradget) << "Setting Garadget to connected" ;
|
||||||
|
thing->setStateValue(garadgetConnectedStateTypeId, true);
|
||||||
|
m_garadgetconnect = 1;
|
||||||
|
}
|
||||||
m_lastActivityTimeStamps[thing] = QDateTime::currentDateTime();
|
m_lastActivityTimeStamps[thing] = QDateTime::currentDateTime();
|
||||||
QJsonParseError error;
|
QJsonParseError error;
|
||||||
QJsonDocument jsonDoc = QJsonDocument::fromJson(payload, &error);
|
QJsonDocument jsonDoc = QJsonDocument::fromJson(payload, &error);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue