Skip to content

Commit

Permalink
fix(TaskProcessing\Manager): Don't provoke PHP notice in setTaskResult
Browse files Browse the repository at this point in the history
Signed-off-by: Marcel Klehr <[email protected]>
  • Loading branch information
marcelklehr authored and backportbot[bot] committed Oct 2, 2024
1 parent fcf45b6 commit ab8078a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/private/TaskProcessing/Manager.php
Original file line number Diff line number Diff line change
Expand Up @@ -921,7 +921,7 @@ public function setTaskResult(int $id, ?string $error, ?array $result, bool $isU
if ($value instanceof Node) {
$output[$key] = $value->getId();
}
if (is_array($value) && $value[0] instanceof Node) {
if (is_array($value) && isset($value[0]) && $value[0] instanceof Node) {
$output[$key] = array_map(fn ($node) => $node->getId(), $value);
}
}
Expand Down

0 comments on commit ab8078a

Please sign in to comment.