Skip to content

Commit

Permalink
Code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
lucatacconi committed Mar 13, 2024
1 parent c8e44ae commit 5eabf9f
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions routes/api/task-stat.php
Original file line number Diff line number Diff line change
Expand Up @@ -639,9 +639,8 @@ static function (array $file) {
if(empty($crunz_config["source"])) throw new Exception("ERROR - Tasks directory configuration empty");
if(empty($crunz_config["suffix"])) throw new Exception("ERROR - Wrong tasks configuration");

if(empty($forced_task_path)){
$TASKS_DIR = $crunz_base_dir . "/" . ltrim($crunz_config["source"], "/");
}else{
$TASKS_DIR = $crunz_base_dir . "/" . ltrim($crunz_config["source"], "/");
if(!empty($forced_task_path)){
$TASKS_DIR = $forced_task_path;
}

Expand Down Expand Up @@ -707,9 +706,8 @@ static function (array $file) {

if(empty($crunz_config["source"])) throw new Exception("ERROR - Tasks directory configuration empty");

if(empty($forced_task_path)){
$TASKS_DIR = $crunz_base_dir . "/" . ltrim($crunz_config["source"], "/");
}else{
$TASKS_DIR = $crunz_base_dir . "/" . ltrim($crunz_config["source"], "/");
if(!empty($forced_task_path)){
$TASKS_DIR = $forced_task_path;
}

Expand Down

0 comments on commit 5eabf9f

Please sign in to comment.