mambax7/smartfaq

View on GitHub

Showing 374 of 649 total issues

Avoid deeply nested control flow statements.
Open

                    if (placeX < 0) placeX = 0;
Severity: Major
Found in assets/js/overlib/overlib_followscroll.js - About 45 mins to fix

    Function ol_content_background_cssstyle has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
    Open

    function ol_content_background_cssstyle(text, picture, hasfullhtml) {
        if (hasfullhtml) {
            txt = text;
        } else {
            var pU, hU, wU;
    Severity: Minor
    Found in assets/js/overlib/mini/overlib_cssstyle_mini.js - About 45 mins 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

    Avoid deeply nested control flow statements.
    Open

            if (o3_shadowy > 0) {
                posStr[0] = ' left:0; top:' + Y + 'px';
                posStr[1] = ' left:' + X + 'px; top:0';
            } else if (o3_shadowy < 0) {
                posStr[0] = ' left:0; top:0';
    Severity: Major
    Found in assets/js/overlib/mini/overlib_shadow_mini.js - About 45 mins to fix

      Function ol_content_background has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
      Open

      function ol_content_background(text, picture, hasfullhtml) {
          if (hasfullhtml) {
              txt = text;
          } else {
              txt = '<table width="' + o3_width + '" border="0" cellpadding="0" cellspacing="0" height="' + o3_height + '"><tr><td colspan="3" height="' + o3_padyt + '"></td></tr><tr><td width="' + o3_padxl + '"></td><td valign="TOP" width="' + (o3_width - o3_padxl - o3_padxr) + (o3_textfontclass ? '" class="' + o3_textfontclass : '') + '">' + (o3_textfontclass ? '' : wrapStr(0, o3_textsize, 'text')) + text + (o3_textfontclass ? '' : wrapStr(1, o3_textsize)) + '</td><td width="' + o3_padxr + '"></td></tr><tr><td colspan="3" height="' + o3_padyb + '"></td></tr></table>';
      Severity: Minor
      Found in assets/js/overlib/overlib.js - About 45 mins 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 ol_content_caption_cssstyle has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
      Open

      function ol_content_caption_cssstyle(text, title, close) {
          var nameId;
          closing = "";
          closeevent = "onMouseOver";
          if (o3_closeclick == 1) closeevent = (o3_closetitle ? "title='" + o3_closetitle + "'" : "") + " onClick";
      Severity: Minor
      Found in assets/js/overlib/mini/overlib_cssstyle_mini.js - About 45 mins 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

      Avoid deeply nested control flow statements.
      Open

                  if (last == 'number') hookPt.alt[pms[optPm - 1 - pmStart]] = fnRef;
      Severity: Major
      Found in assets/js/overlib/mini/overlib_mini.js - About 45 mins to fix

        Avoid deeply nested control flow statements.
        Open

                            if (placeX < 0) placeX = 0;
        Severity: Major
        Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 45 mins to fix

          Avoid deeply nested control flow statements.
          Open

                  if (o3_shadowy > 0) {
                      posStr[0] = ' left:0; top:' + Y + 'px';
                      posStr[1] = ' left:' + X + 'px; top:0';
                  } else if (o3_shadowy < 0) {
                      posStr[0] = ' left:0; top:0';
          Severity: Major
          Found in assets/js/overlib/overlib_shadow.js - About 45 mins to fix

            Function hideObject has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
            Open

            function hideObject(obj) {
                runHook("hideObject", FBEFORE);
                var theObj = (olNs4 ? obj : obj.style);
                if (olNs6 && olShowId > 0) {
                    clearTimeout(olShowId);
            Severity: Minor
            Found in assets/js/overlib/mini/overlib_mini.js - About 45 mins 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

            Avoid deeply nested control flow statements.
            Open

                                if (placeX < 0) placeX = 0;
            Severity: Major
            Found in assets/js/overlib/mini/overlib_followscroll_mini.js - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

                              for (var i = 0; i < fnRef.length; i++) if (hookPt[j] == fnRef[i]) {
                                  match = true;
                                  break;
                              }
              Severity: Major
              Found in assets/js/overlib/mini/overlib_mini.js - About 45 mins to fix

                Function frmDepth has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                Open

                function frmDepth(thisFrame, ofrm) {
                    var retVal = '';
                    for (var i = 0; i < thisFrame.length; i++) {
                        if (thisFrame[i].length > 0) {
                            retVal = frmDepth(thisFrame[i], ofrm);
                Severity: Minor
                Found in assets/js/overlib/mini/overlib_crossframe_mini.js - About 45 mins 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 frmDepth has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                Open

                function frmDepth(thisFrame, ofrm) {
                    var retVal = '';
                
                    for (var i = 0; i < thisFrame.length; i++) {
                        if (thisFrame[i].length > 0) {
                Severity: Minor
                Found in assets/js/overlib/overlib_crossframe.js - About 45 mins 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

                Avoid deeply nested control flow statements.
                Open

                                    if (typeof ar[i + 1] != 'number') v = ar[++i];
                Severity: Major
                Found in assets/js/overlib/overlib.js - About 45 mins to fix

                  Function set_background has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                  Open

                  function set_background(pic) {
                      if (pic == "") {
                          if (olNs4) {
                              over.background.src = null;
                          } else if (over.style) {
                  Severity: Minor
                  Found in assets/js/overlib/overlib.js - About 45 mins 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

                  Avoid deeply nested control flow statements.
                  Open

                                      if (typeof ar[i + 1] != 'number') {
                                          v = ar[++i];
                                          ol_function = (typeof v == 'function' ? v : null);
                                      }
                  Severity: Major
                  Found in assets/js/overlib/overlib.js - About 45 mins to fix

                    Avoid deeply nested control flow statements.
                    Open

                                        if (typeof ar[i + 1] != 'number') {
                                            v = ar[++i];
                                            ol_function = (typeof v == 'function' ? v : null);
                                        }
                    Severity: Major
                    Found in assets/js/overlib/mini/overlib_mini.js - About 45 mins to fix

                      Function opt_FUNCTION has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                      Open

                      function opt_FUNCTION(callme) {
                          o3_text = (callme ? (typeof callme == 'string' ? (/.+\(.*\)/.test(callme) ? eval(callme) : callme) : callme()) : (o3_function ? o3_function() : 'No Function'));
                          return 0;
                      }
                      Severity: Minor
                      Found in assets/js/overlib/mini/overlib_mini.js - About 45 mins 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

                      Avoid deeply nested control flow statements.
                      Open

                                          if (typeof ar[i + 1] != 'number') v = ar[++i];
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_mini.js - About 45 mins to fix

                        Avoid deeply nested control flow statements.
                        Open

                                        if (hookPt[j] == order[i]) {
                                            match = true;
                                            break;
                                        }
                        Severity: Major
                        Found in assets/js/overlib/mini/overlib_mini.js - About 45 mins to fix
                          Severity
                          Category
                          Status
                          Source
                          Language