if last is not initd when an AP is added, set to 0
This commit is contained in:
parent
30a0877de7
commit
8655f986ac
1 changed files with 3 additions and 0 deletions
|
@ -83,6 +83,9 @@ uint8_t wifi_manager_add_ap(char *ssid, char *password) {
|
||||||
|
|
||||||
++ap_store.count;
|
++ap_store.count;
|
||||||
|
|
||||||
|
if(ap_store.last == -1)
|
||||||
|
ap_store.last = 0;
|
||||||
|
|
||||||
wifi_manager_save_config();
|
wifi_manager_save_config();
|
||||||
|
|
||||||
return ap_store.count;
|
return ap_store.count;
|
||||||
|
|
Loading…
Reference in a new issue