commands from WebUI no longer CaseSensitive

This commit is contained in:
Marcel Peterkau 2022-05-15 22:48:25 +02:00
parent b874c7dd30
commit cadaf60087

View File

@ -193,9 +193,10 @@ void WebserverNotFound_Callback(AsyncWebServerRequest *request)
void WebserverCommands_Callback(String input) void WebserverCommands_Callback(String input)
{ {
String command = input.substring(0, input.indexOf(' ')); String command = input.substring(0, input.indexOf(' '));
command.toUpperCase();
StatusResponseMessage_Type = RESPMSG_HIDE; StatusResponseMessage_Type = RESPMSG_HIDE;
if (command == "reset") if (command == "RESET")
{ {
strcpy(StatusResponseMessage, "Counter Reset done"); strcpy(StatusResponseMessage, "Counter Reset done");
StatusResponseMessage_Type = RESPMSG_SUCCESS; StatusResponseMessage_Type = RESPMSG_SUCCESS;