Code Duplication    Length = 5-5 lines in 2 locations

src/PhpSpreadsheet/Worksheet/Worksheet.php 2 locations

@@ 1191-1195 (lines=5) @@
1188
        }
1189
1190
        // Worksheet reference?
1191
        if (strpos($pCoordinate, '!') !== false) {
1192
            $worksheetReference = self::extractSheetTitle($pCoordinate, true);
1193
1194
            return $this->parent->getSheetByName($worksheetReference[0])->getCell(strtoupper($worksheetReference[1]), $createIfNotExists);
1195
        }
1196
1197
        // Named range?
1198
        if ((!preg_match('/^' . Calculation::CALCULATION_REGEXP_CELLREF . '$/i', $pCoordinate, $matches)) &&
@@ 1292-1296 (lines=5) @@
1289
    public function cellExists($pCoordinate)
1290
    {
1291
        // Worksheet reference?
1292
        if (strpos($pCoordinate, '!') !== false) {
1293
            $worksheetReference = self::extractSheetTitle($pCoordinate, true);
1294
1295
            return $this->parent->getSheetByName($worksheetReference[0])->cellExists(strtoupper($worksheetReference[1]));
1296
        }
1297
1298
        // Named range?
1299
        if ((!preg_match('/^' . Calculation::CALCULATION_REGEXP_CELLREF . '$/i', $pCoordinate, $matches)) &&