mambax7/extcal

View on GitHub

Showing 1,163 of 1,163 total issues

Identical blocks of code found in 3 locations. Consider refactoring.
Open

            this.fullExpandLabel = hs.createElement(
                'a', {
                    href: 'javascript:hs.expanders[' + this.key + '].doFullExpand();',
                    title: hs.lang.fullExpandTitle,
                    className: 'highslide-full-expand'
Severity: Major
Found in assets/js/highslide.js and 2 other locations - About 1 hr to fix
assets/js/highslide-full.js on lines 2932..2938
assets/js/highslide-with-gallery.js on lines 2343..2349

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 56.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Function focus has 26 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        focus: function () {
            this.wrapper.style.zIndex = hs.zIndexCounter += 2;
            // blur others
            for (var i = 0; i < hs.expanders.length; i++) {
                if (hs.expanders[i] && i == hs.focusKey) {
Severity: Minor
Found in assets/js/highslide-full.js - About 1 hr to fix

    Method orderedWeekdays has 26 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        public static function orderedWeekdays($Calendar, $format = 'long')
        {
            $days = self::weekdayNames($format);
    
            if (isset($Calendar->tableHelper)) {
    Severity: Minor
    Found in class/pear/Calendar/Util/Textual.php - About 1 hr to fix

      Method bExtcalNewEdit has 26 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function bExtcalNewEdit($options)
      {
          global $xoopsUser;
      
          $helper = Helper::getInstance();
      Severity: Minor
      Found in blocks/new_events.php - About 1 hr to fix

        Function DetectFlashVer has 26 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function DetectFlashVer(reqMajorVer, reqMinorVer, reqRevision) {
            versionStr = GetSwfVer();
            if (versionStr == -1) {
                return false;
            } else if (versionStr != 0) {
        Severity: Minor
        Found in assets/js/AC_RunActiveContent.js - About 1 hr to fix

          Method monthNames has 26 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              public static function monthNames($format = 'long')
              {
                  $formats = [
                      'one'   => 'b',
                      'two'   => 'b',
          Severity: Minor
          Found in class/pear/Calendar/Util/Textual.php - About 1 hr to fix

            Consider simplifying this complex logical expression.
            Open

                        if (!hs.container) {
            
                            hs.ieLt7 = hs.ie && hs.uaVersion < 7;
                            hs.ieLt9 = hs.ie && hs.uaVersion < 9;
            
            
            Severity: Major
            Found in assets/js/highslide.js - About 1 hr to fix

              Method agenda_getEvents has 8 arguments (exceeds 4 allowed). Consider refactoring.
              Open

                  $eventsArray,
                  $ts,
                  $hStart,
                  $hEnd,
                  $mPlage = 15,
              Severity: Major
              Found in include/agenda_fnc.php - About 1 hr to fix

                Method extcal_SendMail has 8 arguments (exceeds 4 allowed). Consider refactoring.
                Open

                    $destinataires,
                    $mail_fromname,
                    $mail_fromemail,
                    $mail_subject,
                    $mail_body,
                Severity: Major
                Found in include/mail_fnc.php - About 1 hr to fix

                  Method getSearchEvent3 has 8 arguments (exceeds 4 allowed). Consider refactoring.
                  Open

                          $queryarray,
                          $andor,
                          $limit,
                          $offset,
                          $userId,
                  Severity: Major
                  Found in class/EventHandler.php - About 1 hr to fix

                    Method PclTarHandleExtractByIndex has 8 arguments (exceeds 4 allowed). Consider refactoring.
                    Open

                            $p_tar,
                            &$p_index_current,
                            $p_index_start,
                            $p_index_stop,
                            &$p_list_detail,
                    Severity: Major
                    Found in class/pcltar.lib.php - About 1 hr to fix

                      Identical blocks of code found in 3 locations. Consider refactoring.
                      Open

                              previousOrNext: function (el, op) {
                                  var exp = hs.getExpander(el);
                                  if (exp) return hs.transit(exp.getAdjacentAnchor(op), exp);
                                  else return false;
                              },
                      Severity: Major
                      Found in assets/js/highslide.js and 2 other locations - About 1 hr to fix
                      assets/js/highslide-full.js on lines 588..592
                      assets/js/highslide-with-gallery.js on lines 445..449

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 55.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

                      Similar blocks of code found in 2 locations. Consider refactoring.
                      Open

                                  hs.setStyles(content, {
                                      width: (x.imgSize || x.size) + 'px',
                                      height: (y.imgSize || y.size) + 'px'
                                  });
                      Severity: Major
                      Found in assets/js/highslide-full.js and 1 other location - About 1 hr to fix
                      assets/js/highslide-with-gallery.js on lines 1682..1685

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 55.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

                      Similar blocks of code found in 2 locations. Consider refactoring.
                      Open

                                  hs.setStyles(content, {
                                      width: (x.imgSize || x.size) + 'px',
                                      height: (y.imgSize || y.size) + 'px'
                                  });
                      Severity: Major
                      Found in assets/js/highslide-with-gallery.js and 1 other location - About 1 hr to fix
                      assets/js/highslide-full.js on lines 2165..2168

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 55.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

                      Identical blocks of code found in 3 locations. Consider refactoring.
                      Open

                              previousOrNext: function (el, op) {
                                  var exp = hs.getExpander(el);
                                  if (exp) return hs.transit(exp.getAdjacentAnchor(op), exp);
                                  else return false;
                              },
                      Severity: Major
                      Found in assets/js/highslide-with-gallery.js and 2 other locations - About 1 hr to fix
                      assets/js/highslide-full.js on lines 588..592
                      assets/js/highslide.js on lines 301..305

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 55.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

                      Identical blocks of code found in 3 locations. Consider refactoring.
                      Open

                              previousOrNext: function (el, op) {
                                  var exp = hs.getExpander(el);
                                  if (exp) return hs.transit(exp.getAdjacentAnchor(op), exp);
                                  else return false;
                              },
                      Severity: Major
                      Found in assets/js/highslide-full.js and 2 other locations - About 1 hr to fix
                      assets/js/highslide-with-gallery.js on lines 445..449
                      assets/js/highslide.js on lines 301..305

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 55.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

                      Identical blocks of code found in 2 locations. Consider refactoring.
                      Open

                              if (\is_object($criteria) && \is_subclass_of($criteria, \CriteriaElement::class)) {
                                  $sql .= ' ' . $criteria->renderWhere();
                                  if ('' != $criteria->getSort()) {
                                      $sql .= ' ORDER BY ' . $criteria->getSort() . ' ' . $criteria->getOrder();
                                  }
                      Severity: Minor
                      Found in class/ExtcalPersistableObjectHandler.php and 1 other location - About 1 hr to fix
                      class/ExtcalPersistableObjectHandler.php on lines 139..146

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 100.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

                      Identical blocks of code found in 2 locations. Consider refactoring.
                      Open

                              if (\is_object($criteria) && \is_subclass_of($criteria, \CriteriaElement::class)) {
                                  $sql .= ' ' . $criteria->renderWhere();
                                  if ('' != $criteria->getSort()) {
                                      $sql .= ' ORDER BY ' . $criteria->getSort() . ' ' . $criteria->getOrder();
                                  }
                      Severity: Minor
                      Found in class/ExtcalPersistableObjectHandler.php and 1 other location - About 1 hr to fix
                      class/ExtcalPersistableObjectHandler.php on lines 226..233

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 100.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

                      Identical blocks of code found in 2 locations. Consider refactoring.
                      Open

                                  if (this.outline && !this.outlineWhileAnimating) {
                                      if (up) this.outline.setPosition();
                                      else this.outline.destroy();
                                  }
                      Severity: Minor
                      Found in assets/js/highslide-with-gallery.js and 1 other location - About 55 mins to fix
                      assets/js/highslide.js on lines 1317..1320

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 54.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

                      Identical blocks of code found in 2 locations. Consider refactoring.
                      Open

                                  if (this.outline && !this.outlineWhileAnimating) {
                                      if (up) this.outline.setPosition();
                                      else this.outline.destroy();
                                  }
                      Severity: Minor
                      Found in assets/js/highslide.js and 1 other location - About 55 mins to fix
                      assets/js/highslide-with-gallery.js on lines 1565..1568

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 54.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

                      Severity
                      Category
                      Status
                      Source
                      Language