fix shell-select for customer ftp-accounts if shell is enabled; fix typo in UserCommand

Signed-off-by: Michael Kaufmann <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann
2022-10-06 14:23:56 +02:00
parent 13c53b074c
commit a37beef18e
4 changed files with 13 additions and 7 deletions

View File

@@ -133,8 +133,11 @@ if ($page == 'overview' || $page == 'accounts') {
$shells['/bin/false'] = "/bin/false";
$shells_avail = Settings::Get('system.available_shells');
if (!empty($shells_avail)) {
$shells_avail = explode(",", $shells_avail);
$shells_avail = array_map("trim", $shells_avail);
$shells_avail_arr = explode(",", $shells_avail);
$shells_avail_arr = array_map("trim", $shells_avail_arr);
foreach ($shells_avail_arr as $shell) {
$shells[$shell] = $shell;
}
}
}
@@ -180,8 +183,11 @@ if ($page == 'overview' || $page == 'accounts') {
$shells['/bin/false'] = "/bin/false";
$shells_avail = Settings::Get('system.available_shells');
if (!empty($shells_avail)) {
$shells_avail = explode(",", $shells_avail);
$shells_avail = array_map("trim", $shells_avail);
$shells_avail_arr = explode(",", $shells_avail);
$shells_avail_arr = array_map("trim", $shells_avail_arr);
foreach ($shells_avail_arr as $shell) {
$shells[$shell] = $shell;
}
}
}