Skip to content

Commit 8761f80

Browse files
committed
minor symfony#37804 [Console] Revert changes to Table->fillCells() (GMTA)
This PR was merged into the 4.4 branch. Discussion ---------- [Console] Revert changes to Table->fillCells() | Q | A | ------------- | --- | Branch? | 4.4 | Bug fix? | no | New feature? | no | Deprecations? | no | Tickets | N/A | License | MIT | Doc PR | N/A These changes were introduced in symfony#37731 but no longer contributed to the actual fix, which was to perform a ->copyRow(). Commits ------- 17263ca Revert changes to Table->fillCells()
2 parents 0f92b9a + 17263ca commit 8761f80

File tree

1 file changed

+2
-6
lines changed
  • src/Symfony/Component/Console/Helper

1 file changed

+2
-6
lines changed

src/Symfony/Component/Console/Helper/Table.php

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -674,16 +674,12 @@ private function fillCells($row)
674674
{
675675
$newRow = [];
676676

677-
$newColumn = null;
678677
foreach ($row as $column => $cell) {
679-
if (null === $newColumn) {
680-
$newColumn = $column;
681-
}
682-
$newRow[$newColumn++] = $cell;
678+
$newRow[] = $cell;
683679
if ($cell instanceof TableCell && $cell->getColspan() > 1) {
684680
foreach (range($column + 1, $column + $cell->getColspan() - 1) as $position) {
685681
// insert empty value at column position
686-
$newRow[$newColumn++] = '';
682+
$newRow[] = '';
687683
}
688684
}
689685
}

0 commit comments

Comments
 (0)