Rename variables to match code style
This commit is contained in:
parent
39e6a46665
commit
8b939f9418
@ -31,7 +31,7 @@ private:
|
|||||||
WebApiSysstatusClass _webApiSysstatus;
|
WebApiSysstatusClass _webApiSysstatus;
|
||||||
WebApiWebappClass _webApiWebapp;
|
WebApiWebappClass _webApiWebapp;
|
||||||
WebApiWsLiveClass _webApiWsLive;
|
WebApiWsLiveClass _webApiWsLive;
|
||||||
unsigned long lastTimerCall = 0;
|
unsigned long _lastWsCleanup = 0;
|
||||||
|
|
||||||
void onWebsocketEvent(AsyncWebSocket* server, AsyncWebSocketClient* client, AwsEventType type, void* arg, uint8_t* data, size_t len);
|
void onWebsocketEvent(AsyncWebSocket* server, AsyncWebSocketClient* client, AwsEventType type, void* arg, uint8_t* data, size_t len);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -47,9 +47,9 @@ void WebApiClass::loop()
|
|||||||
_webApiWsLive.loop();
|
_webApiWsLive.loop();
|
||||||
|
|
||||||
// see: https://github.com/me-no-dev/ESPAsyncWebServer#limiting-the-number-of-web-socket-clients
|
// see: https://github.com/me-no-dev/ESPAsyncWebServer#limiting-the-number-of-web-socket-clients
|
||||||
if (millis() - lastTimerCall > 1000) {
|
if (millis() - _lastWsCleanup > 1000) {
|
||||||
_ws.cleanupClients();
|
_ws.cleanupClients();
|
||||||
lastTimerCall = millis();
|
_lastWsCleanup = millis();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user