diff --git a/WiFiManager.cpp b/WiFiManager.cpp index 88e3a9b..3fbbb42 100644 --- a/WiFiManager.cpp +++ b/WiFiManager.cpp @@ -115,7 +115,7 @@ void WiFiManager::setupConfigPortal() { server->on("/wifisave", std::bind(&WiFiManager::handleWifiSave, this)); server->on("/i", std::bind(&WiFiManager::handleInfo, this)); server->on("/r", std::bind(&WiFiManager::handleReset, this)); - server->on("/generate_204", std::bind(&WiFiManager::handle204, this)); //Android/Chrome OS captive portal check. + //server->on("/generate_204", std::bind(&WiFiManager::handle204, this)); //Android/Chrome OS captive portal check. server->on("/fwlink", std::bind(&WiFiManager::handleRoot, this)); //Microsoft captive portal. Maybe not needed. Might be handled by notFound handler. server->onNotFound (std::bind(&WiFiManager::handleNotFound, this)); server->begin(); // Web server start @@ -403,9 +403,6 @@ void WiFiManager::handleWifi(boolean scan) { for (int i = 0; i < n; i++) { for (int j = i + 1; j < n; j++) { if (WiFi.RSSI(indices[j]) > WiFi.RSSI(indices[i])) { - //int temp = indices[j]; - //indices[j] = indices[i]; - //indices[i] = temp; std::swap(indices[i], indices[j]); } } @@ -651,14 +648,14 @@ void WiFiManager::handleReset() { - -void WiFiManager::handle204() { +//removed as mentioned here https://github.com/tzapu/WiFiManager/issues/114 +/*void WiFiManager::handle204() { DEBUG_WM(F("204 No Response")); server->sendHeader("Cache-Control", "no-cache, no-store, must-revalidate"); server->sendHeader("Pragma", "no-cache"); server->sendHeader("Expires", "-1"); server->send ( 204, "text/plain", ""); -} +}*/ void WiFiManager::handleNotFound() { if (captivePortal()) { // If captive portal redirect instead of displaying the error page.