show users reports error if not admin

This commit is contained in:
proddy
2025-11-29 14:48:13 +01:00
parent 6569b8c038
commit a2baa50530
2 changed files with 7 additions and 2 deletions

View File

@@ -997,6 +997,11 @@ int8_t System::wifi_quality(int8_t dBm) {
// print users to console
void System::show_users(uuid::console::Shell & shell) {
if (!shell.has_flags(CommandFlags::ADMIN)) {
shell.printfln("Unauthorized. You need to be an admin to view users.");
return;
}
shell.printfln("Users:");
#ifndef EMSESP_STANDALONE