mambax7/smartfaq

View on GitHub
assets/js/overlib/mini/overlib_anchor_mini.js

Summary

Maintainability
F
3 wks
Test Coverage

Function anchorPlaceLayer has a Cognitive Complexity of 125 (exceeds 5 allowed). Consider refactoring.
Open

function anchorPlaceLayer() {
    var placeX, placeY, widthFix = 0;
    if (eval('o3_frame.' + docRoot) && eval("typeof o3_frame." + docRoot + ".clientWidth=='number'") && eval('o3_frame.' + docRoot + '.clientWidth')) {
        iwidth = eval('o3_frame.' + docRoot + '.clientWidth');
    } else if (typeof(o3_frame.innerWidth) == 'number') {
Severity: Minor
Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 2 days 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 getAnchorOffsets has a Cognitive Complexity of 56 (exceeds 5 allowed). Consider refactoring.
Open

function getAnchorOffsets(mkObj) {
    var fx = fy = 0, mp, puc, mkAry, sx = sy = 0, w = o3_anchoralign
    var mW = mH = pW = pH = 0
    var off = [0, 0]
    mkAry = w.split(',');
Severity: Minor
Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 1 day 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 anchorPlaceLayer has 87 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function anchorPlaceLayer() {
    var placeX, placeY, widthFix = 0;
    if (eval('o3_frame.' + docRoot) && eval("typeof o3_frame." + docRoot + ".clientWidth=='number'") && eval('o3_frame.' + docRoot + '.clientWidth')) {
        iwidth = eval('o3_frame.' + docRoot + '.clientWidth');
    } else if (typeof(o3_frame.innerWidth) == 'number') {
Severity: Major
Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 3 hrs to fix

    File overlib_anchor_mini.js has 308 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    //\/////
    //\  overLIB Anchor Plugin
    //\  This file requires overLIB 4.00 or later.
    //\
    //\  overLIB 4.05 - You may not remove or change this notice.
    Severity: Minor
    Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 3 hrs to fix

      Function getAnchorOffsets has 74 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function getAnchorOffsets(mkObj) {
          var fx = fy = 0, mp, puc, mkAry, sx = sy = 0, w = o3_anchoralign
          var mW = mH = pW = pH = 0
          var off = [0, 0]
          mkAry = w.split(',');
      Severity: Major
      Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 2 hrs to fix

        Function getRefById has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring.
        Open

        function getRefById(l, d) {
            var r = "", j
            d = (d || document)
            if (d.all) return d.all[l]
            else if (d.getElementById) return d.getElementById(l)
        Severity: Minor
        Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 1 hr 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 getRefByName has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring.
        Open

        function getRefByName(l, d) {
            var r = null, j
            d = (d || document)
            if (d.images[l]) return d.images[l]
            else if (d.anchors[l]) return d.anchors[l]; else if (d.layers && d.layers.length > 0) {
        Severity: Minor
        Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 1 hr 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 getAnchorLocation has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring.
        Open

        function getAnchorLocation(objRef) {
            var mkObj, of, offsets, mlyr
            mkObj = mlyr = objRef
            offsets = [o3_anchorx, o3_anchory]
            if (document.layers) {
        Severity: Minor
        Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 1 hr 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 getAnchorLocation has 34 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function getAnchorLocation(objRef) {
            var mkObj, of, offsets, mlyr
            mkObj = mlyr = objRef
            offsets = [o3_anchorx, o3_anchory]
            if (document.layers) {
        Severity: Minor
        Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 1 hr to fix

          Function parseAnchorExtras has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
          Open

          function parseAnchorExtras(pf, i, ar) {
              var v, k = i;
              if (k < ar.length) {
                  if (ar[k] == ANCHOR) {
                      eval(pf + "anchor='" + escSglQuote(ar[++k]) + "'");
          Severity: Minor
          Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 1 hr 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

          Consider simplifying this complex logical expression.
          Open

              if (typeof o3_scroll != 'undefined' && o3_scroll && o3_sticky && (o3_relx || o3_rely) && (typeof o3_draggable == 'undefined' || !o3_draggable)) {
                  if (typeof over.scroller == 'undefined' || over.scroller.canScroll) over.scroller = new scroller(placeX - winoffset, placeY - scrolloffset, setTimeout("repositionOver()", 20));
              }
          Severity: Major
          Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 1 hr 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 too many return statements within this function.
              Open

                  return -1;
              Severity: Major
              Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 30 mins to fix

                Avoid too many return statements within this function.
                Open

                    return false
                Severity: Major
                Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 30 mins to fix

                  Avoid too many return statements within this function.
                  Open

                              return k;
                  Severity: Major
                  Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 30 mins to fix

                    Avoid too many return statements within this function.
                    Open

                        return null
                    Severity: Major
                    Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 30 mins to fix

                      Function checkAnchorObject has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                      Open

                      function checkAnchorObject() {
                          var w = o3_anchor;
                          if (w) {
                              if (!(mrkObj = getAnchorObjectRef(w))) {
                                  if (o3_noanchorwarn) {
                      Severity: Minor
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js - About 25 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

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

                          if (o3_anchor) {
                              placeX = rmrkPosition[0];
                              placeY = rmrkPosition[1];
                          } else {
                              winoffset = (olIe4) ? eval('o3_frame.' + docRoot + '.scrollLeft') : o3_frame.pageXOffset;
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 5 days to fix
                      assets/js/overlib/mini/overlib_followscroll_mini.js on lines 43..118

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

                      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

                      function getAnchorLocation(objRef) {
                          var mkObj, of, offsets, mlyr
                          mkObj = mlyr = objRef
                          offsets = [o3_anchorx, o3_anchory]
                          if (document.layers) {
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 2 days to fix
                      assets/js/overlib/overlib_anchor.js on lines 256..298

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

                      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

                          if (typeof o3_dragimg != 'undefined' && o3_dragimg) return off; else {
                              if (!isNaN(puc) || typeof puc == 'object') {
                                  if (typeof puc == 'object') {
                                      fx = parseFloat(puc[0]);
                                      fy = parseFloat(puc[1]);
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 1 day to fix
                      assets/js/overlib/overlib_anchor.js on lines 362..385

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

                      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

                      function parseAnchorExtras(pf, i, ar) {
                          var v, k = i;
                          if (k < ar.length) {
                              if (ar[k] == ANCHOR) {
                                  eval(pf + "anchor='" + escSglQuote(ar[++k]) + "'");
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 1 day to fix
                      assets/js/overlib/overlib_anchor.js on lines 63..90

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

                      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

                          if (mkAry.length < 3) {
                              mp = mkAry[0].toUpperCase();
                              puc = (mkAry.length == 1) ? mp : mkAry[1].toUpperCase();
                          } else if (mkAry.length == 3) {
                              if (!isNaN(mkAry[0])) {
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 1 day to fix
                      assets/js/overlib/overlib_anchor.js on lines 308..322

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

                      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

                      function getRefByName(l, d) {
                          var r = null, j
                          d = (d || document)
                          if (d.images[l]) return d.images[l]
                          else if (d.anchors[l]) return d.anchors[l]; else if (d.layers && d.layers.length > 0) {
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 7 hrs to fix
                      assets/js/overlib/overlib_anchor.js on lines 421..437

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

                      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

                      function getRefById(l, d) {
                          var r = "", j
                          d = (d || document)
                          if (d.all) return d.all[l]
                          else if (d.getElementById) return d.getElementById(l)
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 7 hrs to fix
                      assets/js/overlib/overlib_anchor.js on lines 402..418

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

                      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 (!isNaN(mp) || typeof mp == 'object') {
                              if (typeof mp == 'object') {
                                  fx = parseFloat(mp[0]);
                                  fy = parseFloat(mp[1]);
                              } else
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 7 hrs to fix
                      assets/js/overlib/overlib_anchor.js on lines 349..360

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

                      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

                          if (eval('o3_frame.' + docRoot) && eval("typeof o3_frame." + docRoot + ".clientWidth=='number'") && eval('o3_frame.' + docRoot + '.clientWidth')) {
                              iwidth = eval('o3_frame.' + docRoot + '.clientWidth');
                          } else if (typeof(o3_frame.innerWidth) == 'number') {
                              widthFix = Math.ceil(1.2 * (o3_frame.outerWidth - o3_frame.innerWidth));
                              iwidth = o3_frame.innerWidth;
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 2 other locations - About 4 hrs to fix
                      assets/js/overlib/mini/overlib_followscroll_mini.js on lines 37..42
                      assets/js/overlib/mini/overlib_mini.js on lines 425..430

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

                      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

                          if (typeof o3_scroll != 'undefined' && o3_scroll && o3_sticky && (o3_relx || o3_rely) && (typeof o3_draggable == 'undefined' || !o3_draggable)) {
                              if (typeof over.scroller == 'undefined' || over.scroller.canScroll) over.scroller = new scroller(placeX - winoffset, placeY - scrolloffset, setTimeout("repositionOver()", 20));
                          }
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 3 hrs to fix
                      assets/js/overlib/overlib_anchor.js on lines 236..238

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

                      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

                          if (olOp && o3_wrap) {
                              pW = (shdwPresent ? parseInt(o3_width) : (olNs4 ? over.clip.width : over.offsetWidth))
                              pH = (shdwPresent ? parseInt(o3_aboveheight) : (olNs4 ? over.clip.height : over.offsetHeight))
                          }
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 2 hrs to fix
                      assets/js/overlib/overlib_anchor.js on lines 334..337

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

                      function pageLocation(o, t) {
                          var x = 0
                          while (o.offsetParent) {
                              x += o['offset' + t]
                              o = o.offsetParent
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 1 hr to fix
                      assets/js/overlib/mini/overlib_hideform_mini.js on lines 70..78

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

                      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

                      function checkAnchorObject() {
                          var w = o3_anchor;
                          if (w) {
                              if (!(mrkObj = getAnchorObjectRef(w))) {
                                  if (o3_noanchorwarn) {
                      Severity: Major
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 1 hr to fix
                      assets/js/overlib/overlib_anchor.js on lines 96..109

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

                      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

                          } else if (!olOp && mkObj.toString().indexOf('Anchor') != -1) {
                              mp = 'UL'
                          } else {
                              mW = (olNs4) ? mkObj.clip.width : mkObj.offsetWidth
                              mH = (olNs4) ? mkObj.clip.height : mkObj.offsetHeight
                      Severity: Minor
                      Found in assets/js/overlib/mini/overlib_anchor_mini.js and 1 other location - About 55 mins to fix
                      assets/js/overlib/overlib_anchor.js on lines 342..347

                      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

                      There are no issues that match your filters.

                      Category
                      Status