Merge pull request #1988 from Ciki/patch-1

Fix deprecated warning for non-hexadecimal number
This commit is contained in:
troosan 2021-02-05 21:16:25 +01:00 committed by GitHub
commit 3c66ce9a73
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -52,6 +52,7 @@ class Table extends AbstractElement
for ($j = 0; $j < $rowCellCount; $j++) {
$cellStyle = $rowCells[$j]->getStyle();
$cellBgColor = $cellStyle->getBgColor();
$cellBgColor === 'auto' && $cellBgColor = null; // auto cannot be parsed to hexadecimal number
$cellFgColor = null;
if ($cellBgColor) {
$red = hexdec(substr($cellBgColor, 0, 2));