Skip to content

Commit

Permalink
Merge pull request #15 from boseji/master
Browse files Browse the repository at this point in the history
Adding Safer reset method for /wifi/rst path
  • Loading branch information
r-downing authored Oct 29, 2018
2 parents e55fb50 + 4e97638 commit acd6784
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion PersWiFiManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,11 @@ void PersWiFiManager::setupWiFiHandlers() {
_server->on("/wifi/rst", [&]() {
_server->send(200, "text/html", "Rebooting...");
delay(100);
ESP.restart();
//ESP.restart();
// Adding Safer Restart method
ESP.wdtDisable();
ESP.reset();
delay(2000);
});

#ifdef WIFI_HTM_PROGMEM
Expand Down

0 comments on commit acd6784

Please sign in to comment.