Code Duplication    Length = 5-5 lines in 2 locations

catalog/includes/apps/paypal/OSCOM_PayPal.php 2 locations

@@ 200-204 (lines=5) @@
197
                         'OSCOM_APP_PAYPAL_PF_' . $server . '_PASSWORD',
198
                         'OSCOM_APP_PAYPAL_PF_' . $server . '_PARTNER');
199
        }
200
      } else {
201
        $creds = array('OSCOM_APP_PAYPAL_' . $server . '_API_USERNAME',
202
                       'OSCOM_APP_PAYPAL_' . $server . '_API_PASSWORD',
203
                       'OSCOM_APP_PAYPAL_' . $server . '_API_SIGNATURE');
204
      }
205
206
      foreach ( $creds as $c ) {
207
        if ( !defined($c) || (strlen(trim(constant($c))) < 1) ) {
@@ 246-250 (lines=5) @@
243
        $creds = array('OSCOM_APP_PAYPAL_' . $server . '_SELLER_EMAIL');
244
      } elseif ( substr($type, 0, 7) == 'payflow' ) {
245
        $creds = array('OSCOM_APP_PAYPAL_PF_' . $server . '_' . strtoupper(substr($type, 8)));
246
      } else {
247
        $creds = array('OSCOM_APP_PAYPAL_' . $server . '_API_USERNAME',
248
                       'OSCOM_APP_PAYPAL_' . $server . '_API_PASSWORD',
249
                       'OSCOM_APP_PAYPAL_' . $server . '_API_SIGNATURE');
250
      }
251
252
      foreach ( $creds as $c ) {
253
        if ( !defined($c) || (strlen(trim(constant($c))) < 1) ) {