diff --git a/src/Cezpdf.php b/src/Cezpdf.php index 44a4e41..d5654ff 100644 --- a/src/Cezpdf.php +++ b/src/Cezpdf.php @@ -1293,10 +1293,10 @@ public function ezTable(&$data, $cols = '', $title = '', $options = '') $widest = 0; foreach ($cols0 as $colName => $w) { if ($w > $widest) { - $aWidest = [$colName]; + array_unshift($aWidest, $colName); $nWidest = $widest; $widest = $w; - } elseif ($w == $widest) { + } else { $aWidest[] = $colName; } }