Code Duplication    Length = 9-9 lines in 2 locations

checkout.php 2 locations

@@ 447-455 (lines=9) @@
444
            OledrionUtility::redirect(_OLEDRION_ERROR20, OLEDRION_URL, 4);
445
        }
446
        // Check checkout level
447
        if ($checkout_level == 1) {
448
            OledrionUtility::redirect(_OLEDRION_FINAL_CHECKOUT, OLEDRION_URL . 'checkout.php?op=confirm&commend_id=' . $commend_id, 1);
449
            // B.R. Start
450
        } elseif ($checkoutAttributes['skip_location'] == 1) {
451
            //$commande = $h_oledrion_commands->get($commend_id);
452
            //OledrionUtility::redirect(_OLEDRION_SELECT_DELIVERY, OLEDRION_URL . 'checkout.php?op=delivery&commend_id=' . $commande->getVar('cmd_id'), 1);
453
            OledrionUtility::redirect(_OLEDRION_SELECT_DELIVERY, OLEDRION_URL . 'checkout.php?op=delivery&commend_id=' . $commend_id, 1);
454
            // B.R. End
455
        }
456
        // B.R. listCart();
457
        switch ($action) {
458
            case 'default':
@@ 506-514 (lines=9) @@
503
            OledrionUtility::redirect(_OLEDRION_ERROR20, OLEDRION_URL, 4);
504
        }
505
        // Check checkout level
506
        if ($checkout_level == 1) {
507
            OledrionUtility::redirect(_OLEDRION_FINAL_CHECKOUT, OLEDRION_URL . 'checkout.php?op=confirm&commend_id=' . $commend_id, 1);
508
            // B.R. Start
509
        } elseif ($checkoutAttributes['skip_delivery'] == 1) {
510
            //$commande = $h_oledrion_commands->get($commend_id);
511
            //OledrionUtility::redirect(_OLEDRION_SELECT_PAYMENT, OLEDRION_URL . 'checkout.php?op=payment&commend_id=' . $commande->getVar('cmd_id'), 1);
512
            OledrionUtility::redirect(_OLEDRION_SELECT_PAYMENT, OLEDRION_URL . 'checkout.php?op=payment&commend_id=' . $commend_id, 1);
513
            // B.R. End
514
        }
515
        // B.R. listCart();
516
        $commande    = $h_oledrion_commands->get($commend_id);
517
        $location_id = $commande->getVar('cmd_location_id');