fix recurcivity

This commit is contained in:
atm-greg 2018-08-09 12:21:48 +02:00
parent 4e16f64af0
commit 3d84adbd76

View File

@ -719,14 +719,12 @@ class Project extends CommonObject
{
global $user;
$arrParents = array();
foreach($arr as $task)
{
if($task->hasChildren() < 0) $task->delete($user);
else $arrParents[] = $task;
if($task->hasChildren() <= 0) $task->delete($user);
}
if (count($arrParents)) $this->deleteTasks($arrParents);
$this->getLinesArray($user);
if (count($this->lines)) $this->deleteTasks($this->lines);
}
/**