PromisePay/promisepay-php

View on GitHub
lib/DataObjects/Widget.php

Summary

Maintainability
C
1 day
Test Coverage

Widget has 55 functions (exceeds 20 allowed). Consider refactoring.
Open

class Widget
{

    private $_itemName;

Severity: Major
Found in lib/DataObjects/Widget.php - About 7 hrs to fix

    File Widget.php has 280 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    <?php
    namespace PromisePay\DataObjects;
    
    /**
     * Class Widget
    Severity: Minor
    Found in lib/DataObjects/Widget.php - About 2 hrs to fix

      Method __construct has 29 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          public function __construct($jsonData)
          {
              if (count($jsonData)) {
                  $this->_itemName                = array_key_exists('item_name', $jsonData)?$jsonData['item_name']:'';
                  $this->_fullAmount              = array_key_exists('full_amount', $jsonData)?$jsonData['full_amount']:'';
      Severity: Minor
      Found in lib/DataObjects/Widget.php - About 1 hr to fix

        There are no issues that match your filters.

        Category
        Status