mirror of
https://github.com/PHPOffice/PhpSpreadsheet.git
synced 2026-09-02 13:41:21 +00:00
fix php 8.1 error when autoFilter['ref'] is null
This commit is contained in:
committed by
Adrien Crivelli
parent
ef839f56be
commit
1a4e4ed7c5
@@ -22,7 +22,7 @@ class AutoFilter
|
||||
public function load(): void
|
||||
{
|
||||
// Remove all "$" in the auto filter range
|
||||
$autoFilterRange = preg_replace('/\$/', '', $this->worksheetXml->autoFilter['ref']);
|
||||
$autoFilterRange = preg_replace('/\$/', '', $this->worksheetXml->autoFilter['ref'] ?? '');
|
||||
if (strpos($autoFilterRange, ':') !== false) {
|
||||
$this->readAutoFilter($autoFilterRange, $this->worksheetXml);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user