Refactor PHP request handling and return codes.

This commit is contained in:
Lars Jung 2015-05-01 20:29:36 +02:00
parent e275ecac07
commit 6ad53ec2aa
5 changed files with 50 additions and 53 deletions

View file

@ -101,7 +101,7 @@ class Bootstrap {
// EXTERNAL COMMANDS
$cmds = Util::load_commented_json(CMDS_PATH);
if (sizeof($cmds) === 0 || Util::has_request_param("updatecmds")) {
if (sizeof($cmds) === 0 || Util::get_boolean_request_param("updatecmds", false)) {
$cmds["command"] = Util::exec_0("command -v command");
$cmds["which"] = Util::exec_0("which which");