Skip to content

Commit b399c09

Browse files
author
MarkBaker
committed
Performance Experiment for the String Table, to avoid creating empty cells; should also be slightly faster
1 parent d686a99 commit b399c09

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/PhpSpreadsheet/Writer/Xlsx/StringTable.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ public function createStringTable(Worksheet $worksheet, $existingTable = null)
3535
$aFlippedStringTable = $this->flipStringTable($aStringTable);
3636

3737
// Loop through cells
38-
foreach ($worksheet->getCoordinates() as $coordinate) {
39-
$cell = $worksheet->getCell($coordinate);
38+
foreach ($worksheet->getCellCollection()->getCoordinates() as $coordinate) {
39+
$cell = $worksheet->getCellCollection()->get($coordinate);
4040
$cellValue = $cell->getValue();
4141
if (
4242
!is_object($cellValue) &&

0 commit comments

Comments
 (0)