mirror of
https://git.mirrors.martin98.com/https://github.com/luc-github/ESP3D.git
synced 2025-08-05 13:40:43 +08:00
Fix [ESP] help not displayed in web command
This commit is contained in:
parent
4aa503741f
commit
20ae0c92da
@ -263,27 +263,27 @@ bool Commands::ESP0(const char* cmd_params, level_authenticate_type auth_type, E
|
||||
const uint cmdNb = sizeof(help)/sizeof(char*);
|
||||
parameter = get_param (cmd_params, "");
|
||||
if (parameter.length() == 0) {
|
||||
output->printMSG("[List of ESP3D commands]");
|
||||
output->printLN("[List of ESP3D commands]");
|
||||
for (uint i = 0; i < cmdNb -1; i++) {
|
||||
output->printMSG(help[i]);
|
||||
output->printLN(help[i]);
|
||||
}
|
||||
} else {
|
||||
bool found = false;
|
||||
uint cmdval = String(cmd_params).toInt();
|
||||
if (sizeof(help)/sizeof(char*) != sizeof(cmdlist)/sizeof(uint)) {
|
||||
output->printMSG("Error in code");
|
||||
output->printLN("Error in code");
|
||||
return false;
|
||||
}
|
||||
for (uint i = 0; i < cmdNb-1; i++) {
|
||||
if (cmdlist[i] == cmdval) {
|
||||
output->printMSG(help[i]);
|
||||
output->printLN(help[i]);
|
||||
found = true;
|
||||
}
|
||||
}
|
||||
if (!found) {
|
||||
String tmp = "This command is not supported: ";
|
||||
tmp+= cmd_params;
|
||||
output->printMSG(tmp.c_str());
|
||||
output->printLN(tmp.c_str());
|
||||
}
|
||||
}
|
||||
return response;
|
||||
|
@ -22,7 +22,7 @@
|
||||
#define _VERSION_ESP3D_H
|
||||
|
||||
//version and sources location
|
||||
#define FW_VERSION "3.0.0.a36"
|
||||
#define FW_VERSION "3.0.0.a37"
|
||||
#define REPOSITORY "https://github.com/luc-github/ESP3D/tree/3.0"
|
||||
|
||||
#endif //_VERSION_ESP3D_H
|
||||
|
Loading…
x
Reference in New Issue
Block a user