Avoid warning if variable is null

This commit is contained in:
troosan 2018-12-28 20:32:10 +01:00
parent d8d697c848
commit ccf291234e
1 changed files with 1 additions and 1 deletions

View File

@ -47,7 +47,7 @@ class Table extends AbstractStyle
$xmlWriter->endElement(); // style:style
$cellWidths = $style->getColumnWidths();
$countCellWidths = count($cellWidths);
$countCellWidths = $cellWidths === null ? 0 : count($cellWidths);
for ($i = 0; $i < $countCellWidths; $i++) {
$width = $cellWidths[$i];