Code Duplication    Length = 13-13 lines in 2 locations

catalog/includes/apps/braintree/OSCOM_Braintree.php 1 location

@@ 584-596 (lines=13) @@
581
      return $this->_title;
582
    }
583
584
    function getVersion() {
585
      if ( !isset($this->_version) ) {
586
        $version = trim(file_get_contents(DIR_FS_CATALOG . 'includes/apps/braintree/version.txt'));
587
588
        if ( is_numeric($version) ) {
589
          $this->_version = $version;
590
        } else {
591
          trigger_error('OSCOM APP [BRAINTREE]: Could not read App version number.');
592
        }
593
      }
594
595
      return $this->_version;
596
    }
597
598
    function getApiVersion() {
599
      return $this->_api_version;

catalog/includes/apps/paypal/OSCOM_PayPal.php 1 location

@@ 636-648 (lines=13) @@
633
      return $this->_title;
634
    }
635
636
    function getVersion() {
637
      if ( !isset($this->_version) ) {
638
        $version = trim(file_get_contents(DIR_FS_CATALOG . 'includes/apps/paypal/version.txt'));
639
640
        if ( is_numeric($version) ) {
641
          $this->_version = $version;
642
        } else {
643
          trigger_error('OSCOM APP [PAYPAL]: Could not read App version number.');
644
        }
645
      }
646
647
      return $this->_version;
648
    }
649
650
    function getApiVersion() {
651
      return $this->_api_version;