Merge branch 'master' into Column-Autofit-Indentation

This commit is contained in:
MarkBaker 2022-05-11 19:00:43 +02:00
commit 4a4078f38f
2 changed files with 5 additions and 1 deletions

View File

@ -4197,7 +4197,7 @@ parameters:
- -
message: "#^Strict comparison using \\=\\=\\= between string and null will always evaluate to false\\.$#" message: "#^Strict comparison using \\=\\=\\= between string and null will always evaluate to false\\.$#"
count: 1 count: 2
path: src/PhpSpreadsheet/Worksheet/Worksheet.php path: src/PhpSpreadsheet/Worksheet/Worksheet.php
- -

View File

@ -3014,6 +3014,10 @@ class Worksheet implements IComparable
*/ */
public static function extractSheetTitle(string $range, $returnRange = false) public static function extractSheetTitle(string $range, $returnRange = false)
{ {
if ($range === null) {
return $returnRange ? [null, null] : null;
}
// Sheet title included? // Sheet title included?
if (($sep = strrpos($range, '!')) === false) { if (($sep = strrpos($range, '!')) === false) {
return $returnRange ? ['', $range] : ''; return $returnRange ? ['', $range] : '';