mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-15 12:19:58 +03:00
show users reports error if not admin
This commit is contained in:
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user