Code Duplication    Length = 9-9 lines in 2 locations

src/PhpSpreadsheet/Calculation.php 2 locations

@@ 3559-3567 (lines=9) @@
3556
                            $sheet2 = $sheet1;
3557
                        }
3558
                        if ($sheet1 == $sheet2) {
3559
                            if ($operand1Data['reference'] === null) {
3560
                                if ((trim($operand1Data['value']) != '') && (is_numeric($operand1Data['value']))) {
3561
                                    $operand1Data['reference'] = $pCell->getColumn().$operand1Data['value'];
3562
                                } elseif (trim($operand1Data['reference']) == '') {
3563
                                    $operand1Data['reference'] = $pCell->getCoordinate();
3564
                                } else {
3565
                                    $operand1Data['reference'] = $operand1Data['value'].$pCell->getRow();
3566
                                }
3567
                            }
3568
                            if ($operand2Data['reference'] === null) {
3569
                                if ((trim($operand2Data['value']) != '') && (is_numeric($operand2Data['value']))) {
3570
                                    $operand2Data['reference'] = $pCell->getColumn().$operand2Data['value'];
@@ 3568-3576 (lines=9) @@
3565
                                    $operand1Data['reference'] = $operand1Data['value'].$pCell->getRow();
3566
                                }
3567
                            }
3568
                            if ($operand2Data['reference'] === null) {
3569
                                if ((trim($operand2Data['value']) != '') && (is_numeric($operand2Data['value']))) {
3570
                                    $operand2Data['reference'] = $pCell->getColumn().$operand2Data['value'];
3571
                                } elseif (trim($operand2Data['reference']) == '') {
3572
                                    $operand2Data['reference'] = $pCell->getCoordinate();
3573
                                } else {
3574
                                    $operand2Data['reference'] = $operand2Data['value'].$pCell->getRow();
3575
                                }
3576
                            }
3577
3578
                            $oData = array_merge(explode(':', $operand1Data['reference']), explode(':', $operand2Data['reference']));
3579
                            $oCol = $oRow = array();