also clear disconnect event on GotIP handler

This commit is contained in:
amarofarinha 2024-09-19 09:09:43 +01:00
parent 23c9f8c3c3
commit 4e3aa720d8

View file

@ -155,6 +155,8 @@ static void onWifiConnect(WiFiEvent_t event, WiFiEventInfo_t info) {
// Event handler for Wi-Fi Got IP
static void onWifiGotIP(WiFiEvent_t event, WiFiEventInfo_t info) {
//clear disconnects events if we got a IP
clear_event(EVENT_WIFI_DISCONNECT);
#ifdef DEBUG_VIA_USB
Serial.println("Wi-Fi Got IP.");
Serial.print("IP address: ");