Fix init of wifi last updaded variable
@@ -377,6 +377,9 @@ void DeRestPluginPrivate::initWiFi()
return;
}
+ QDateTime currentDateTime = QDateTime::currentDateTimeUtc();
+ gwWifiLastUpdated = currentDateTime.toTime_t();
+
if (gwWifiState == WifiStateInitMgmt)
{
retry = true;
@@ -446,9 +449,6 @@ void DeRestPluginPrivate::initWiFi()
gwWifiBackupPw = gwWifiPw;
}
- QDateTime currentDateTime = QDateTime::currentDateTimeUtc();
- gwWifiLastUpdated = currentDateTime.toTime_t();
-
queSaveDb(DB_CONFIG, DB_SHORT_SAVE_DELAY);
}
