Code Duplication    Length = 4-4 lines in 2 locations

src/PhpSpreadsheet/Calculation.php 2 locations

@@ 4044-4047 (lines=4) @@
4041
4042
        if ($pSheet !== null) {
4043
            $pSheetName = $pSheet->getTitle();
4044
            if (strpos($pRange, '!') !== false) {
4045
                list($pSheetName, $pRange) = Worksheet::extractSheetTitle($pRange, true);
4046
                $pSheet = $this->spreadsheet->getSheetByName($pSheetName);
4047
            }
4048
4049
            // Extract range
4050
            $aReferences = Cell::extractAllCellReferencesInRange($pRange);
@@ 4095-4098 (lines=4) @@
4092
4093
        if ($pSheet !== null) {
4094
            $pSheetName = $pSheet->getTitle();
4095
            if (strpos($pRange, '!') !== false) {
4096
                list($pSheetName, $pRange) = Worksheet::extractSheetTitle($pRange, true);
4097
                $pSheet = $this->spreadsheet->getSheetByName($pSheetName);
4098
            }
4099
4100
            // Named range?
4101
            $namedRange = NamedRange::resolveRange($pRange, $pSheet);