fix esp32 new bugs

esp32 only uses persistent on wifiLowLevelInit
        if(!persistent){
          esp_wifi_set_storage(WIFI_STORAGE_RAM);
        }
which only gets applied during certain functions, namely changing modes, or turning on wifi
This commit is contained in:
Shawn A
2018-06-18 11:40:01 -05:00
parent 3c8af53440
commit 5066b86102
+4 -2
View File
@@ -155,8 +155,10 @@ void WiFiManager::WiFiManagerInit(){
setMenu(_menuIdsDefault);
if(_debug && _debugLevel > DEBUG_DEV) debugPlatformInfo();
_usermode = WiFi.getMode();
WiFi.persistent(false); // disable persistent so scannetworks and mode switching do not cause overwrites
#ifndef ESP32
_usermode = WiFi.getMode();
WiFi.persistent(false); // disable persistent so scannetworks and mode switching do not cause overwrites
#endif
_max_params = WIFI_MANAGER_MAX_PARAMS;
}