Skip to content

Commit

Permalink
fix(TaskProcessingApiController): Don't use + to merge non-assoc. arrays
Browse files Browse the repository at this point in the history
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
  • Loading branch information
marcelklehr committed Jul 1, 2024
1 parent eed6216 commit 0574d7e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions core/Controller/TaskProcessingApiController.php
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ private function extractFileIdsFromTask(Task $task): array {
/** @var int|list<int> $inputSlot */
$inputSlot = $task->getInput()[$key];
if (is_array($inputSlot)) {
$ids += $inputSlot;
$ids = array_merge($inputSlot, $ids);
} else {
$ids[] = $inputSlot;
}
Expand All @@ -297,14 +297,14 @@ private function extractFileIdsFromTask(Task $task): array {
/** @var int|list<int> $outputSlot */
$outputSlot = $task->getOutput()[$key];
if (is_array($outputSlot)) {
$ids += $outputSlot;
$ids = array_merge($outputSlot, $ids);
} else {
$ids[] = $outputSlot;
}
}
}
}
return array_values($ids);
return $ids;
}

/**
Expand Down

0 comments on commit 0574d7e

Please sign in to comment.