ota.cpp bugfix

This commit is contained in:
Klaus K Wilting 2018-09-19 11:38:29 +02:00
parent 8b2e155576
commit c33112c3b4

View File

@ -216,7 +216,7 @@ void processOTAUpdate(const String &version) {
TAG, TAG,
"OTA update completed. Rebooting to runmode with new version."); "OTA update completed. Rebooting to runmode with new version.");
client.stop(); client.stop();
ESP.restart(); return;
} else { } else {
ESP_LOGI(TAG, "Something went wrong! OTA update hasn't been finished " ESP_LOGI(TAG, "Something went wrong! OTA update hasn't been finished "
"properly."); "properly.");
@ -237,7 +237,6 @@ void processOTAUpdate(const String &version) {
ESP_LOGI(TAG, ESP_LOGI(TAG,
"OTA update failed. Rebooting to runmode with current version."); "OTA update failed. Rebooting to runmode with current version.");
client.stop(); client.stop();
ESP.restart();
} }
// helper function to compare two versions. Returns 1 if v2 is // helper function to compare two versions. Returns 1 if v2 is