Code Duplication    Length = 7-7 lines in 2 locations

catalog/includes/modules/payment/paypal_express.php 2 locations

@@ 280-286 (lines=7) @@
277
        } elseif ( !tep_session_is_registered('appPayPalEcSecret') || ($appPayPalEcResult['PAYMENTREQUEST_0_CUSTOM'] != $appPayPalEcSecret) ) {
278
          tep_redirect(tep_href_link(FILENAME_SHOPPING_CART, '', 'SSL'));
279
        }
280
      } else { // Payflow
281
        if ($appPayPalEcResult['RESULT'] != '0') {
282
          tep_redirect(tep_href_link(FILENAME_SHOPPING_CART, 'error_message=' . urlencode($appPayPalEcResult['OSCOM_ERROR_MESSAGE']), 'SSL'));
283
        } elseif ( !tep_session_is_registered('appPayPalEcSecret') || ($appPayPalEcResult['CUSTOM'] != $appPayPalEcSecret) ) {
284
          tep_redirect(tep_href_link(FILENAME_SHOPPING_CART, '', 'SSL'));
285
        }
286
      }
287
288
      $order->info['payment_method'] = '<img src="https://www.paypalobjects.com/webstatic/mktg/Logo/pp-logo-100px.png" border="0" alt="PayPal Logo" style="padding: 3px;" />';
289
    }
@@ 383-389 (lines=7) @@
380
        tep_redirect(tep_href_link('ext/modules/payment/paypal/express.php', '', 'SSL'));
381
      }
382
383
      if ( $appPayPalEcResult['RESULT'] == '0' ) {
384
        if ( !tep_session_is_registered('appPayPalEcSecret') || ($appPayPalEcResult['CUSTOM'] != $appPayPalEcSecret) ) {
385
          tep_redirect(tep_href_link(FILENAME_SHOPPING_CART, '', 'SSL'));
386
        }
387
      } else {
388
        tep_redirect(tep_href_link(FILENAME_SHOPPING_CART, 'error_message=' . urlencode($appPayPalEcResult['OSCOM_ERROR_MESSAGE']), 'SSL'));
389
      }
390
391
      if ( empty($comments) ) {
392
        if ( isset($HTTP_POST_VARS['ppecomments']) && tep_not_null($HTTP_POST_VARS['ppecomments']) ) {