fix several issues with updater (refs #562)
This commit is contained in:
parent
ccc50f9220
commit
08da1c6a23
|
@ -27,15 +27,17 @@ class Updater extends Plugin {
|
|||
$work_dir = dirname(dirname(dirname(__FILE__)));
|
||||
$parent_dir = dirname($work_dir);
|
||||
|
||||
if (!chdir($work_dir)) {
|
||||
array_push($log, "Unable to change to work directory: $work_dir");
|
||||
$stop = true; break;
|
||||
}
|
||||
|
||||
$stop = false;
|
||||
$log = array();
|
||||
if (!is_array($params)) $params = array();
|
||||
|
||||
$stop = false;
|
||||
|
||||
if (!chdir($work_dir)) {
|
||||
array_push($log, "Unable to change to work directory: $work_dir");
|
||||
$stop = true;
|
||||
}
|
||||
|
||||
if (!$stop) {
|
||||
switch ($step) {
|
||||
case 0:
|
||||
array_push($log, "Work directory: $work_dir");
|
||||
|
@ -241,6 +243,7 @@ class Updater extends Plugin {
|
|||
default:
|
||||
$stop = true;
|
||||
}
|
||||
}
|
||||
|
||||
return array("step" => $step, "stop" => $stop, "params" => $params, "log" => $log);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue