Code Duplication    Length = 4-4 lines in 2 locations

src/PhpSpreadsheet/Calculation.php 2 locations

@@ 4081-4084 (lines=4) @@
4078
4079
        if ($pSheet !== null) {
4080
            $pSheetName = $pSheet->getTitle();
4081
            if (strpos($pRange, '!') !== false) {
4082
                list($pSheetName, $pRange) = Worksheet::extractSheetTitle($pRange, true);
4083
                $pSheet = $this->spreadsheet->getSheetByName($pSheetName);
4084
            }
4085
4086
            // Extract range
4087
            $aReferences = Cell::extractAllCellReferencesInRange($pRange);
@@ 4132-4135 (lines=4) @@
4129
4130
        if ($pSheet !== null) {
4131
            $pSheetName = $pSheet->getTitle();
4132
            if (strpos($pRange, '!') !== false) {
4133
                list($pSheetName, $pRange) = Worksheet::extractSheetTitle($pRange, true);
4134
                $pSheet = $this->spreadsheet->getSheetByName($pSheetName);
4135
            }
4136
4137
            // Named range?
4138
            $namedRange = NamedRange::resolveRange($pRange, $pSheet);