mambax7/extcal

View on GitHub

Showing 691 of 1,163 total issues

Method PclTarHandleHeader has 80 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    function PclTarHandleHeader($p_tar, $p_filename, $p_mode, &$p_header, $p_stored_filename)
    {
        TrFctStart(__FILE__, __LINE__, 'PclTarHandleHeader', "tar=$p_tar, file='$p_filename', mode='$p_mode', stored_filename='$p_stored_filename'");
        $v_result = 1;

Severity: Major
Found in class/pcltar.lib.php - About 3 hrs to fix

    Function Expander has 79 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        hs.Expander = function (a, params, custom, contentType) {
            if (document.readyState && hs.ie && !hs.isReady) {
                hs.addEventListener(document, 'ready', function () {
                    new hs.Expander(a, params, custom, contentType);
                });
    Severity: Major
    Found in assets/js/highslide-with-gallery.js - About 3 hrs to fix

      Function AC_GetArgs has 79 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function AC_GetArgs(args, ext, srcParamName, classid, mimeType) {
          var ret = new Object();
          ret.embedAttrs = new Object();
          ret.params = new Object();
          ret.objAttrs = new Object();
      Severity: Major
      Found in assets/js/AC_RunActiveContent.js - About 3 hrs to fix

        Function correctRatio has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
        Open

                correctRatio: function (ratio) {
                    var x = this.x,
                        y = this.y,
                        changed = false,
                        xSize = Math.min(x.full, x.size),
        Severity: Minor
        Found in assets/js/highslide-full.js - About 3 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 initSlideshow has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
        Open

                initSlideshow: function () {
                    if (!this.last) {
                        for (var i = 0; i < hs.slideshows.length; i++) {
                            var ss = hs.slideshows[i], sg = ss.slideshowGroup;
                            if (typeof sg == 'undefined' || sg === null || sg === this.slideshowGroup)
        Severity: Minor
        Found in assets/js/highslide-full.js - About 3 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 correctRatio has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
        Open

                correctRatio: function (ratio) {
                    var x = this.x,
                        y = this.y,
                        changed = false,
                        xSize = Math.min(x.full, x.size),
        Severity: Minor
        Found in assets/js/highslide.js - About 3 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 correctRatio has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
        Open

                correctRatio: function (ratio) {
                    var x = this.x,
                        y = this.y,
                        changed = false,
                        xSize = Math.min(x.full, x.size),
        Severity: Minor
        Found in assets/js/highslide-with-gallery.js - About 3 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 initSlideshow has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
        Open

                initSlideshow: function () {
                    if (!this.last) {
                        for (var i = 0; i < hs.slideshows.length; i++) {
                            var ss = hs.slideshows[i], sg = ss.slideshowGroup;
                            if (typeof sg == 'undefined' || sg === null || sg === this.slideshowGroup)
        Severity: Minor
        Found in assets/js/highslide-with-gallery.js - About 3 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

        Method PclTarHandleAddFile has 77 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            function PclTarHandleAddFile($p_tar, $p_filename, $p_mode, &$p_header, $p_add_dir, $p_remove_dir)
            {
                TrFctStart(__FILE__, __LINE__, 'PclTarHandleAddFile', "tar='$p_tar', filename='$p_filename', p_mode='$p_mode', add_dir='$p_add_dir', remove_dir='$p_remove_dir'");
                $v_result = 1;
        
        
        Severity: Major
        Found in class/pcltar.lib.php - About 3 hrs to fix

          Method xoops_module_update_extcal has 75 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          function xoops_module_update_extcal(\XoopsModule $module, $previousVersion = null)
          {
              //    global $xoopsDB;
              $moduleDirName = \basename(\dirname(__DIR__));
          
          
          Severity: Major
          Found in include/onupdate.php - About 3 hrs to fix

            FormSpin has 26 functions (exceeds 20 allowed). Consider refactoring.
            Open

            class FormSpin extends \XoopsFormElement
            {
                /**
                 * Value.
                 *
            Severity: Minor
            Found in class/Form/Spin/FormSpin.php - About 3 hrs to fix

              Function Expander has 75 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  hs.Expander = function (a, params, custom, contentType) {
                      if (document.readyState && hs.ie && !hs.isReady) {
                          hs.addEventListener(document, 'ready', function () {
                              new hs.Expander(a, params, custom, contentType);
                          });
              Severity: Major
              Found in assets/js/highslide.js - About 3 hrs to fix

                Function changeSize has 73 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-full.js - About 2 hrs to fix

                  Function updateAnchors has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring.
                  Open

                          updateAnchors: function () {
                              var el, els, all = [], images = [], htmls = [], groups = {}, re;
                  
                              for (var i = 0; i < hs.openerTagNames.length; i++) {
                                  els = document.getElementsByTagName(hs.openerTagNames[i]);
                  Severity: Minor
                  Found in assets/js/highslide-full.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 focus has a Cognitive Complexity of 21 (exceeds 5 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-with-gallery.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 focus has a Cognitive Complexity of 21 (exceeds 5 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.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 getOverlays has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring.
                  Open

                          getOverlays: function () {
                              this.getInline(['heading', 'caption'], true);
                              if (this.heading && this.dragByHeading) this.heading.className += ' highslide-move';
                              if (hs.showCredits) this.writeCredits();
                              for (var i = 0; i < hs.overlays.length; i++) {
                  Severity: Minor
                  Found in assets/js/highslide.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 bExtcalMinicalShow has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring.
                  Open

                  function bExtcalMinicalShow($options)
                  {
                      global $xoopsUser;
                  
                      extcal_getDefautminicalOption($options);
                  Severity: Minor
                  Found in blocks/minical.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 createOverlay has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring.
                  Open

                          createOverlay: function (o) {
                              var el = o.overlayId;
                              if (typeof el == 'string') el = hs.getNode(el);
                              if (o.html) el = hs.createElement('div', {innerHTML: o.html});
                              if (!el || typeof el == 'string') return;
                  Severity: Minor
                  Found in assets/js/highslide.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 PclTarExtractList has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring.
                  Open

                      function PclTarExtractList($p_tarname, $p_filelist, $p_path = './', $p_remove_path = '', $p_mode = '')
                      {
                          TrFctStart(__FILE__, __LINE__, 'PclTarExtractList', "tar=$p_tarname, list, path=$p_path, remove_path='$p_remove_path', mode='$p_mode'");
                          $v_result = 1;
                  
                  
                  Severity: Minor
                  Found in class/pcltar.lib.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

                  Severity
                  Category
                  Status
                  Source
                  Language