GemsTracker/gemstracker-library

View on GitHub
classes/Gems/Default/ContactAction.php

Summary

Maintainability
A
2 hrs
Test Coverage
F
0%

Method _getOrganizationsList has 40 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    protected function _getOrganizationsList()
    {
        $html = new \MUtil_Html_Sequence();
        $sql = '
            SELECT *
Severity: Minor
Found in classes/Gems/Default/ContactAction.php - About 1 hr to fix

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

        public function supportAction()
        {
            $this->initHtml();
    
            $this->html->h3($this->_('Support'));
    Severity: Minor
    Found in classes/Gems/Default/ContactAction.php - About 1 hr to fix

      Avoid variables with short names like $p. Configured minimum length is 3.
      Open

                      $p = $html->pInfo(sprintf($this->_('%s is run by: '), $this->project->getName()));

      ShortVariable

      Since: 0.2

      Detects when a field, local, or parameter has a very short name.

      Example

      class Something {
          private $q = 15; // VIOLATION - Field
          public static function main( array $as ) { // VIOLATION - Formal
              $r = 20 + $this->q; // VIOLATION - Local
              for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                  $r += $this->q;
              }
          }
      }

      Source https://phpmd.org/rules/naming.html#shortvariable

      Avoid variables with short names like $li. Configured minimum length is 3.
      Open

                      $li = $ul->li();

      ShortVariable

      Since: 0.2

      Detects when a field, local, or parameter has a very short name.

      Example

      class Something {
          private $q = 15; // VIOLATION - Field
          public static function main( array $as ) { // VIOLATION - Formal
              $r = 20 + $this->q; // VIOLATION - Local
              for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                  $r += $this->q;
              }
          }
      }

      Source https://phpmd.org/rules/naming.html#shortvariable

      Avoid variables with short names like $ul. Configured minimum length is 3.
      Open

                      $ul = $p->ul($data, array('class' => 'indent'));

      ShortVariable

      Since: 0.2

      Detects when a field, local, or parameter has a very short name.

      Example

      class Something {
          private $q = 15; // VIOLATION - Field
          public static function main( array $as ) { // VIOLATION - Formal
              $r = 20 + $this->q; // VIOLATION - Local
              for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                  $r += $this->q;
              }
          }
      }

      Source https://phpmd.org/rules/naming.html#shortvariable

      Avoid variables with short names like $ul. Configured minimum length is 3.
      Open

              $ul = $menuItem->toUl($this->getRequest());

      ShortVariable

      Since: 0.2

      Detects when a field, local, or parameter has a very short name.

      Example

      class Something {
          private $q = 15; // VIOLATION - Field
          public static function main( array $as ) { // VIOLATION - Formal
              $r = 20 + $this->q; // VIOLATION - Local
              for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
                  $r += $this->q;
              }
          }
      }

      Source https://phpmd.org/rules/naming.html#shortvariable

      There are no issues that match your filters.

      Category
      Status