minor #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 https://github.com/symfony/symfony/pull/37731 but no longer contributed to the actual fix, which was to perform a ->copyRow().
Commits
-------
17263ca14d
Revert changes to Table->fillCells()
This commit is contained in:
commit
8761f80268
@ -674,16 +674,12 @@ class Table
|
||||
{
|
||||
$newRow = [];
|
||||
|
||||
$newColumn = null;
|
||||
foreach ($row as $column => $cell) {
|
||||
if (null === $newColumn) {
|
||||
$newColumn = $column;
|
||||
}
|
||||
$newRow[$newColumn++] = $cell;
|
||||
$newRow[] = $cell;
|
||||
if ($cell instanceof TableCell && $cell->getColspan() > 1) {
|
||||
foreach (range($column + 1, $column + $cell->getColspan() - 1) as $position) {
|
||||
// insert empty value at column position
|
||||
$newRow[$newColumn++] = '';
|
||||
$newRow[] = '';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user