Run shell or earlyshellcmd even if iit's not an array

This commit is contained in:
Scott Ullrich 2005-10-05 01:05:19 +00:00
parent 53dfd34e36
commit 245388b446

View File

@ -741,10 +741,17 @@ function system_do_shell_commands($early = 0) {
$cmdn = "shellcmd";
if (is_array($config['system'][$cmdn])) {
/* *cmd is an array, loop through */
foreach ($config['system'][$cmdn] as $cmd) {
exec($cmd);
}
} elseif($config['system'][$cmdn] <> "") {
/* execute single item */
exec($config['system'][$cmdn]);
}
}