diff --git a/src/WsServer.cpp b/src/WsServer.cpp index c8886ab6..7dd5c8ed 100644 --- a/src/WsServer.cpp +++ b/src/WsServer.cpp @@ -414,6 +414,10 @@ void sendFileToWsByFrames(const String& filename, const String& header, const St } void sendStringToWs(const String& header, String& payload, int client_id) { + if (!(WiFi.softAPgetStationNum() || isNetworkActive())) { + return; + } + if (header.length() != 6) { SerialPrint("E", "FS", F("wrong header size")); return;