mambax7/extcal

View on GitHub

Showing 1,163 of 1,163 total issues

Function changeSize has 59 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        changeSize: function (up, to, dur) {
            // transition
            var trans = this.transitions,
                other = up ? (this.last ? this.last.a : null) : hs.upcoming,
                t = (trans[1] && other
Severity: Major
Found in assets/js/highslide-with-gallery.js - About 2 hrs to fix

    Method agenda_getCanevas has 59 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function agenda_getCanevas($ts, $hStart, $hEnd, $mPlage = 15, $nbJours = 1, $formatDate = '', $formatJour = 'H:i')
    {
        $helper = Helper::getInstance();
        $jour   = date('d', $ts);
        $mois   = date('m', $ts);
    Severity: Major
    Found in include/agenda_fnc.php - About 2 hrs to fix

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

              preloadNext: function () {
                  var next = this.getAdjacentAnchor(1);
                  if (next && next.onclick.toString().match(/hs\.expand/))
                      var img = hs.createElement('img', {src: hs.getSrc(next)});
              },
      Severity: Major
      Found in assets/js/highslide.js and 2 other locations - About 2 hrs to fix
      assets/js/highslide-full.js on lines 2346..2350
      assets/js/highslide-with-gallery.js on lines 1844..1848

      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 82.

      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

              preloadNext: function () {
                  var next = this.getAdjacentAnchor(1);
                  if (next && next.onclick.toString().match(/hs\.expand/))
                      var img = hs.createElement('img', {src: hs.getSrc(next)});
              },
      Severity: Major
      Found in assets/js/highslide-full.js and 2 other locations - About 2 hrs to fix
      assets/js/highslide-with-gallery.js on lines 1844..1848
      assets/js/highslide.js on lines 1400..1404

      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 82.

      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

              preloadNext: function () {
                  var next = this.getAdjacentAnchor(1);
                  if (next && next.onclick.toString().match(/hs\.expand/))
                      var img = hs.createElement('img', {src: hs.getSrc(next)});
              },
      Severity: Major
      Found in assets/js/highslide-with-gallery.js and 2 other locations - About 2 hrs to fix
      assets/js/highslide-full.js on lines 2346..2350
      assets/js/highslide.js on lines 1400..1404

      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 82.

      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 init has 58 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

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

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

                prepareNextOutline: function () {
                    var key = this.key;
                    var outlineType = this.outlineType;
                    new hs.Outline(outlineType,
                        function () {
        Severity: Major
        Found in assets/js/highslide-full.js and 2 other locations - About 2 hrs to fix
        assets/js/highslide-with-gallery.js on lines 1831..1841
        assets/js/highslide.js on lines 1387..1397

        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 81.

        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

                prepareNextOutline: function () {
                    var key = this.key;
                    var outlineType = this.outlineType;
                    new hs.Outline(outlineType,
                        function () {
        Severity: Major
        Found in assets/js/highslide.js and 2 other locations - About 2 hrs to fix
        assets/js/highslide-full.js on lines 2333..2343
        assets/js/highslide-with-gallery.js on lines 1831..1841

        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 81.

        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

                prepareNextOutline: function () {
                    var key = this.key;
                    var outlineType = this.outlineType;
                    new hs.Outline(outlineType,
                        function () {
        Severity: Major
        Found in assets/js/highslide-with-gallery.js and 2 other locations - About 2 hrs to fix
        assets/js/highslide-full.js on lines 2333..2343
        assets/js/highslide.js on lines 1387..1397

        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 81.

        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

        File pcltrace.lib.php has 262 lines of code (exceeds 250 allowed). Consider refactoring.
        Open

        <?php
        // --------------------------------------------------------------------------------
        // PhpConcept Library (PCL) Trace 1.0
        // --------------------------------------------------------------------------------
        // License GNU/GPL - Vincent Blavet - Janvier 2001
        Severity: Minor
        Found in class/pcltrace.lib.php - About 2 hrs to fix

          Function DetectFlashVer has a Cognitive Complexity of 17 (exceeds 5 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 2 hrs to fix

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Function getSearchEvent3 has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring.
          Open

              public function getSearchEvent3(
                  $queryarray,
                  $andor,
                  $limit,
                  $offset,
          Severity: Minor
          Found in class/EventHandler.php - About 2 hrs to fix

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Function positionOverlay has 56 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                  positionOverlay: function (overlay) {
                      var p = overlay.position || 'middle center',
                          offX = overlay.offsetX,
                          offY = overlay.offsetY;
                      if (overlay.parentNode != this.overlayBox) this.overlayBox.appendChild(overlay);
          Severity: Major
          Found in assets/js/highslide.js - About 2 hrs to fix

            Method isBlockCloned has 55 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                function isBlockCloned($bid, $bside, $bweight, $bvisible, $bcachetime, $bmodule, $options)
                {
                    xoops_loadLanguage('admin', 'system');
                    xoops_loadLanguage('admin/blocksadmin', 'system');
                    xoops_loadLanguage('admin/groups', 'system');
            Severity: Major
            Found in admin/blocksadmin.php - About 2 hrs to fix

              Method getEventsUniques has 55 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  public function getEventsUniques($criteres)
                  {
                      $cat = 0;
                      //        while (list($k, $v) = each($criteres)) {
                      foreach ($criteres as $k => $v) {
              Severity: Major
              Found in class/EventHandler.php - About 2 hrs to fix

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

                            hs.extend(overlay, {
                                opacity: 1,
                                offsetX: 0,
                                offsetY: 0,
                                dur: (o.fade === 0 || o.fade === false || (o.fade == 2 && hs.ie)) ? 0 : 250
                Severity: Major
                Found in assets/js/highslide-full.js and 2 other locations - About 2 hrs to fix
                assets/js/highslide-with-gallery.js on lines 2140..2145
                assets/js/highslide.js on lines 1634..1639

                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 79.

                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

                            var exp = this,
                                last = this.last,
                                x = this.x,
                                y = this.y,
                                lastX = last.x,
                Severity: Major
                Found in assets/js/highslide-with-gallery.js and 1 other location - About 2 hrs to fix
                assets/js/highslide-full.js on lines 2154..2162

                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 79.

                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 3 locations. Consider refactoring.
                Open

                            hs.extend(overlay, {
                                opacity: 1,
                                offsetX: 0,
                                offsetY: 0,
                                dur: (o.fade === 0 || o.fade === false || (o.fade == 2 && hs.ie)) ? 0 : 250
                Severity: Major
                Found in assets/js/highslide.js and 2 other locations - About 2 hrs to fix
                assets/js/highslide-full.js on lines 2722..2727
                assets/js/highslide-with-gallery.js on lines 2140..2145

                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 79.

                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

                            var exp = this,
                                last = this.last,
                                x = this.x,
                                y = this.y,
                                lastX = last.x,
                Severity: Major
                Found in assets/js/highslide-full.js and 1 other location - About 2 hrs to fix
                assets/js/highslide-with-gallery.js on lines 1671..1679

                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 79.

                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 3 locations. Consider refactoring.
                Open

                            hs.extend(overlay, {
                                opacity: 1,
                                offsetX: 0,
                                offsetY: 0,
                                dur: (o.fade === 0 || o.fade === false || (o.fade == 2 && hs.ie)) ? 0 : 250
                Severity: Major
                Found in assets/js/highslide-with-gallery.js and 2 other locations - About 2 hrs to fix
                assets/js/highslide-full.js on lines 2722..2727
                assets/js/highslide.js on lines 1634..1639

                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 79.

                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