SU-SWS/stanford_profile_helper

View on GitHub

Showing 521 of 706 total issues

Method createParagraph has 37 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  protected function createParagraph($bundle): EntityInterface {
    // We've already created this paragraph type, just duplicated i.
    if (isset($this->paragraphs[$bundle])) {
      return $this->paragraphs[$bundle]->createDuplicate();
    }

    Method buildConfigurationForm has 32 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

      public function buildConfigurationForm(array $form, FormStateInterface $form_state) {
        $form = parent::buildConfigurationForm($form, $form_state);
    
        // Extra CSS classes.
        $form['extra_classes'] = [
    Severity: Minor
    Found in modules/jumpstart_ui/src/Layouts/JumpstartUiLayouts.php - About 1 hr to fix

      Function attach has 31 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          attach: function attach(context, settings) {
      
            if (settings?.stanfordNews?.hideSocial) {
              return;
            }
      Severity: Minor
      Found in modules/stanford_news/lib/js/news-node.js - About 1 hr to fix

        Method toolbar has 30 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

          public function toolbar() {
            $notification_list = $this->getToolbarTrayItems($this->getUserNotifications());
        
            $items['notifications'] = [
              '#type' => 'toolbar_item',
        Severity: Minor
        Found in modules/stanford_notifications/src/NotificationService.php - About 1 hr to fix

          Avoid using undefined variables such as '$row' which will lead to PHP notices.
          Open

              $row['label'] = $entity->label();

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$requirements' which will lead to PHP notices.
          Open

            $requirements['stanford_person_importer_encrypt'] = [

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$row' which will lead to PHP notices.
          Open

              return $row + parent::buildRow($entity);

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$extra' which will lead to PHP notices.
          Open

            return $extra;

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$themes' which will lead to PHP notices.
          Open

            $themes['rabbit_hole_message'] = [
          Severity: Minor
          Found in stanford_profile_helper.module by phpmd

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$header' which will lead to PHP notices.
          Open

              $header['id'] = $this->t('Machine name');

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$items' which will lead to PHP notices.
          Open

              $items['notifications'] = [

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$row' which will lead to PHP notices.
          Open

              $row['id'] = $entity->id();

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$themes' which will lead to PHP notices.
          Open

            return $themes;
          Severity: Minor
          Found in stanford_profile_helper.module by phpmd

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$themes' which will lead to PHP notices.
          Open

            $themes['block__stanford_basic_search'] = [
          Severity: Minor
          Found in stanford_profile_helper.module by phpmd

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$items' which will lead to PHP notices.
          Open

              return $items;

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$header' which will lead to PHP notices.
          Open

              $header['label'] = $this->t('Citation type');

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$extra' which will lead to PHP notices.
          Open

            $extra['node']['stanford_publication']['display']['citation_type'] = [

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$requirements' which will lead to PHP notices.
          Open

            return $requirements;

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

          Avoid using undefined variables such as '$header' which will lead to PHP notices.
          Open

              return $header + parent::buildHeader();

          UndefinedVariable

          Since: 2.8.0

          Detects when a variable is used that has not been defined before.

          Example

          class Foo
          {
              private function bar()
              {
                  // $message is undefined
                  echo $message;
              }
          }

          Source https://phpmd.org/rules/cleancode.html#undefinedvariable

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

            protected function insertOrgData(array $org_data, TermInterface $parent = NULL): void {
              if (!isset($org_data['orgCodes'])) {
                return;
              }
          
          
            Severity
            Category
            Status
            Source
            Language