XoopsModules25x/apcal

View on GitHub
assets/images/js/highslide/highslide-with-html.js

Summary

Maintainability
F
5 mos
Test Coverage

File highslide-with-html.js has 2232 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/**
 * Name:    Highslide JS
 * Version: 4.1.13 (2011-10-06)
 * Config:  default +inline +ajax +iframe +flash
 * Author:  Torstein Hønsi
Severity: Major
Found in assets/images/js/highslide/highslide-with-html.js - About 6 days to fix

    Consider simplifying this complex logical expression.
    Open

    if (!hs) {
        var hs = {
    // Language strings
            lang: {
                cssDirection: 'ltr',
    Severity: Critical
    Found in assets/images/js/highslide/highslide-with-html.js - About 2 days to fix

      Function getInline has a Cognitive Complexity of 60 (exceeds 5 allowed). Consider refactoring.
      Open

              getInline: function (types, addOverlay) {
                  for (var i = 0; i < types.length; i++) {
                      var type = types[i], s = null;
                      if (!this[type + 'Id'] && this.thumbsUserSetId)
                          this[type + 'Id'] = type + '-for-' + this.thumbsUserSetId;
      Severity: Minor
      Found in assets/images/js/highslide/highslide-with-html.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 changeSize has a Cognitive Complexity of 50 (exceeds 5 allowed). Consider refactoring.
      Open

              changeSize: function (up, to, dur) {
      
                  if (this.outline && !this.outlineWhileAnimating) {
                      if (up) this.outline.setPosition();
                      else this.outline.destroy(
      Severity: Minor
      Found in assets/images/js/highslide/highslide-with-html.js - About 7 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 mouseClickHandler has a Cognitive Complexity of 49 (exceeds 5 allowed). Consider refactoring.
      Open

              mouseClickHandler: function (e) {
                  if (!e) e = window.event;
                  if (e.button > 1) return true;
                  if (!e.target) e.target = e.srcElement;
      
      
      Severity: Minor
      Found in assets/images/js/highslide/highslide-with-html.js - About 7 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 Expander has a Cognitive Complexity of 45 (exceeds 5 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: Minor
      Found in assets/images/js/highslide/highslide-with-html.js - About 6 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

      prototype has 46 functions (exceeds 20 allowed). Consider refactoring.
      Open

          hs.Expander.prototype = {
              error: function (e) {
                  if (hs.debug) alert('Line ' + e.lineNumber + ': ' + e.message);
                  else window.location.href = this.src;
              },
      Severity: Minor
      Found in assets/images/js/highslide/highslide-with-html.js - About 6 hrs to fix

        hs has 44 functions (exceeds 20 allowed). Consider refactoring.
        Open

            var hs = {
        // Language strings
                lang: {
                    cssDirection: 'ltr',
                    loadingText: 'Loading...',
        Severity: Minor
        Found in assets/images/js/highslide/highslide-with-html.js - About 6 hrs to fix

          Function loadHTML has a Cognitive Complexity of 37 (exceeds 5 allowed). Consider refactoring.
          Open

                  loadHTML: function () {
                      var s = this.cachedGet || this.xhr.responseText,
                          regBody;
                      if (this.pre) hs.cachedGets[this.src] = s;
                      if (!hs.ie || hs.uaVersion >= 5.5) {
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.js - About 5 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 showHideElements has a Cognitive Complexity of 37 (exceeds 5 allowed). Consider refactoring.
          Open

                  showHideElements: function (tagName, visibility) {
                      var els = document.getElementsByTagName(tagName);
                      var prop = tagName == '*' ? 'overflow' : 'visibility';
                      for (var i = 0; i < els.length; i++) {
                          if (prop == 'visibility' || (document.defaultView.getComputedStyle(
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.js - About 5 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 justify has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
          Open

                  justify: function (p, moveOnly) {
                      var tgtArr, tgt = p.target, dim = p == this.x ? 'x' : 'y';
          
                      var hasMovedMin = false;
          
          
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.js - About 4 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 31 (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/images/js/highslide/highslide-with-html.js - About 4 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 dragHandler has a Cognitive Complexity of 30 (exceeds 5 allowed). Consider refactoring.
          Open

                  dragHandler: function (e) {
                      if (!hs.dragArgs) return true;
                      if (!e) e = window.event;
                      var a = hs.dragArgs, exp = a.exp;
                      if (exp.iframe) {
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.js - About 4 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 keyHandler has a Cognitive Complexity of 30 (exceeds 5 allowed). Consider refactoring.
          Open

                  keyHandler: function (e) {
                      if (!e) e = window.event;
                      if (!e.target) e.target = e.srcElement; // ie
                      if (typeof e.target.form != 'undefined') return true; // form element has focus
                      var exp = hs.getExpander();
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.js - About 4 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 run has a Cognitive Complexity of 30 (exceeds 5 allowed). Consider refactoring.
          Open

                  run: function () {
                      var xhr;
                      if (!this.src) this.src = hs.getSrc(this.a);
                      if (this.src.match('#')) {
                          var arr = this.src.split('#');
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.js - About 4 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 contentLoaded has a Cognitive Complexity of 28 (exceeds 5 allowed). Consider refactoring.
          Open

                  contentLoaded: function () {
                      try {
                          if (!this.content) return;
                          this.content.onload = null;
                          if (this.onLoadStarted) return;
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.js - About 4 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 27 (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/images/js/highslide/highslide-with-html.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 setSize has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring.
          Open

                  setSize: function (i) {
                      var exp = this.exp;
                      if (exp.isImage && (exp.useBox || hs.padToMinWidth)) {
                          this.imgSize = i;
                          this.size = Math.max(this.size, this.imgSize);
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.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 onGraphicLoad has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring.
          Open

                  onGraphicLoad: function () {
                      var o = this.offset = this.graphic.width / 4,
                          pos = [[0, 0], [0, -4], [-2, 0], [0, -8], 0, [-2, -8], [0, -2], [0, -6], [-2, -2]],
                          dim = {height: (2 * o) + 'px', width: (2 * o) + 'px'};
                      for (var i = 0; i <= 8; i++) {
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.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 htmlCreate has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring.
          Open

                  htmlCreate: function () {
          
                      this.content = hs.getCacheBinding(this.a);
                      if (!this.content)
                          this.content = hs.getNode(this.contentId);
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.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 sizeOverlayBox has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring.
          Open

                  sizeOverlayBox: function (doWrapper, doPanels) {
                      var overlayBox = this.overlayBox,
                          x = this.x,
                          y = this.y;
                      hs.setStyles(overlayBox, {
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.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 getWrapperKey has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring.
          Open

                  getWrapperKey: function (element, expOnly) {
                      var el, re = /^highslide-wrapper-([0-9]+)$/;
                      // 1. look in open expanders
                      el = element;
                      while (el.parentNode) {
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.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 writeExtendedContent has a Cognitive Complexity of 24 (exceeds 5 allowed). Consider refactoring.
          Open

                  writeExtendedContent: function () {
                      if (this.hasExtendedContent) return;
                      var exp = this;
                      this.body = hs.getElementByClass(this.innerContent, 'DIV', 'highslide-body');
                      if (this.objectType == 'iframe') {
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.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 htmlSizeOperations has a Cognitive Complexity of 24 (exceeds 5 allowed). Consider refactoring.
          Open

                  htmlSizeOperations: function () {
          
                      this.setObjContainerSize(this.innerContent);
          
          
          
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.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/images/js/highslide/highslide-with-html.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 Expander has 76 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/images/js/highslide/highslide-with-html.js - About 3 hrs to fix

            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/images/js/highslide/highslide-with-html.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 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/images/js/highslide/highslide-with-html.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 positionOverlay has a Cognitive Complexity of 20 (exceeds 5 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: Minor
            Found in assets/images/js/highslide/highslide-with-html.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 changeSize has 64 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                    changeSize: function (up, to, dur) {
            
                        if (this.outline && !this.outlineWhileAnimating) {
                            if (up) this.outline.setPosition();
                            else this.outline.destroy(
            Severity: Major
            Found in assets/images/js/highslide/highslide-with-html.js - About 2 hrs to fix

              Function htmlCreate has 61 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                      htmlCreate: function () {
              
                          this.content = hs.getCacheBinding(this.a);
                          if (!this.content)
                              this.content = hs.getNode(this.contentId);
              Severity: Major
              Found in assets/images/js/highslide/highslide-with-html.js - About 2 hrs to fix

                Function wrapperMouseHandler has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring.
                Open

                        wrapperMouseHandler: function (e) {
                            try {
                                if (!e) e = window.event;
                                var over = /mouseover/i.test(e.type);
                                if (!e.target) e.target = e.srcElement; // ie
                Severity: Minor
                Found in assets/images/js/highslide/highslide-with-html.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 step has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring.
                Open

                        step: function (gotoEnd) {
                            var t = (new Date()).getTime();
                            if (gotoEnd || t >= this.options.duration + this.startTime) {
                                this.now = this.end;
                                this.pos = this.state = 1;
                Severity: Minor
                Found in assets/images/js/highslide/highslide-with-html.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 mouseClickHandler has 57 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                        mouseClickHandler: function (e) {
                            if (!e) e = window.event;
                            if (e.button > 1) return true;
                            if (!e.target) e.target = e.srcElement;
                
                
                Severity: Major
                Found in assets/images/js/highslide/highslide-with-html.js - About 2 hrs to fix

                  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/images/js/highslide/highslide-with-html.js - About 2 hrs to fix

                    Function custom has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
                    Open

                            custom: function (from, to, unit) {
                                this.startTime = (new Date()).getTime();
                                this.start = from;
                                this.end = to;
                                this.unit = unit;// || this.unit || "px";
                    Severity: Minor
                    Found in assets/images/js/highslide/highslide-with-html.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 afterExpand has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
                    Open

                            afterExpand: function () {
                                this.isExpanded = true;
                                this.focus();
                    
                                if (this.isHtml && this.objectLoadTime == 'after') this.writeExtendedContent();
                    Severity: Minor
                    Found in assets/images/js/highslide/highslide-with-html.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 init has 48 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: Minor
                    Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                      Function htmlPrepareClose has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                      Open

                              htmlPrepareClose: function () {
                                  if (hs.geckoMac) { // bad redraws
                                      if (!hs.mask) hs.mask = hs.createElement('div', null,
                                          {position: 'absolute'}, hs.container);
                                      hs.setStyles(hs.mask, {
                      Severity: Minor
                      Found in assets/images/js/highslide/highslide-with-html.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 expand has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                      Open

                              expand: function (a, params, custom, type) {
                                  if (!a) a = hs.createElement('a', null, {display: 'none'}, hs.container);
                                  if (typeof a.getParams == 'function') return params;
                                  if (type == 'html') {
                                      for (var i = 0; i < hs.sleeping.length; i++) {
                      Severity: Minor
                      Found in assets/images/js/highslide/highslide-with-html.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 contentLoaded has 47 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                              contentLoaded: function () {
                                  try {
                                      if (!this.content) return;
                                      this.content.onload = null;
                                      if (this.onLoadStarted) return;
                      Severity: Minor
                      Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                        Function htmlSizeOperations has 47 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                                htmlSizeOperations: function () {
                        
                                    this.setObjContainerSize(this.innerContent);
                        
                        
                        
                        Severity: Minor
                        Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                          Function run has 44 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                                  run: function () {
                                      var xhr;
                                      if (!this.src) this.src = hs.getSrc(this.a);
                                      if (this.src.match('#')) {
                                          var arr = this.src.split('#');
                          Severity: Minor
                          Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                            Function correctRatio has 41 lines of code (exceeds 25 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/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                              Function keyHandler has 40 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                      keyHandler: function (e) {
                                          if (!e) e = window.event;
                                          if (!e.target) e.target = e.srcElement; // ie
                                          if (typeof e.target.form != 'undefined') return true; // form element has focus
                                          var exp = hs.getExpander();
                              Severity: Minor
                              Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

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

                                    hs.Outline = function (outlineType, onLoad) {
                                        this.onLoad = onLoad;
                                        this.outlineType = outlineType;
                                        var v = hs.uaVersion, tr;
                                
                                
                                Severity: Minor
                                Found in assets/images/js/highslide/highslide-with-html.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 awake has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring.
                                Open

                                        awake: function () {
                                            try {
                                
                                                hs.expanders[this.key] = this;
                                
                                
                                Severity: Minor
                                Found in assets/images/js/highslide/highslide-with-html.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 css has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring.
                                Open

                                        css: function (el, prop) {
                                            if (el.style[prop]) {
                                                return el.style[prop];
                                            } else if (document.defaultView) {
                                                return document.defaultView.getComputedStyle(el, null).getPropertyValue(prop);
                                Severity: Minor
                                Found in assets/images/js/highslide/highslide-with-html.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 get has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring.
                                Open

                                        get: function (key) {
                                            switch (key) {
                                                case 'loadingPos':
                                                    return this.tpos + this.tb + (this.t - hs.loading['offset' + this.ucwh]) / 2;
                                                case 'wsize':
                                Severity: Minor
                                Found in assets/images/js/highslide/highslide-with-html.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 showHideElements has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                        showHideElements: function (tagName, visibility) {
                                            var els = document.getElementsByTagName(tagName);
                                            var prop = tagName == '*' ? 'overflow' : 'visibility';
                                            for (var i = 0; i < els.length; i++) {
                                                if (prop == 'visibility' || (document.defaultView.getComputedStyle(
                                Severity: Minor
                                Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                                  Function loadHTML has 36 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                          loadHTML: function () {
                                              var s = this.cachedGet || this.xhr.responseText,
                                                  regBody;
                                              if (this.pre) hs.cachedGets[this.src] = s;
                                              if (!hs.ie || hs.uaVersion >= 5.5) {
                                  Severity: Minor
                                  Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                                    Function fitOverlayBox has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring.
                                    Open

                                            fitOverlayBox: function (ratio, changed) {
                                                var x = this.x, y = this.y;
                                                if (this.overlayBox && (this.isImage || this.allowHeightReduction)) {
                                                    while (y.size > this.minHeight && x.size > this.minWidth
                                                    && y.get('wsize') > y.get('fitsize')) {
                                    Severity: Minor
                                    Found in assets/images/js/highslide/highslide-with-html.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 init has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring.
                                    Open

                                            init: function () {
                                                if (!hs.container) {
                                    
                                                    hs.ieLt7 = hs.ie && hs.uaVersion < 7;
                                                    hs.ieLt9 = hs.ie && hs.uaVersion < 9;
                                    Severity: Minor
                                    Found in assets/images/js/highslide/highslide-with-html.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 getPageSize has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring.
                                    Open

                                            getPageSize: function () {
                                                var d = document, w = window, iebody = d.compatMode && d.compatMode != 'BackCompat'
                                                        ? d.documentElement : d.body,
                                                    ieLt9 = hs.ie && (hs.uaVersion < 9 || typeof pageXOffset == 'undefined');
                                    
                                    
                                    Severity: Minor
                                    Found in assets/images/js/highslide/highslide-with-html.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 createOverlay has 35 lines of code (exceeds 25 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/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                                      Function getInline has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                              getInline: function (types, addOverlay) {
                                                  for (var i = 0; i < types.length; i++) {
                                                      var type = types[i], s = null;
                                                      if (!this[type + 'Id'] && this.thumbsUserSetId)
                                                          this[type + 'Id'] = type + '-for-' + this.thumbsUserSetId;
                                      Severity: Minor
                                      Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                                        Function onGraphicLoad has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                                onGraphicLoad: function () {
                                                    var o = this.offset = this.graphic.width / 4,
                                                        pos = [[0, 0], [0, -4], [-2, 0], [0, -8], 0, [-2, -8], [0, -2], [0, -6], [-2, -2]],
                                                        dim = {height: (2 * o) + 'px', width: (2 * o) + 'px'};
                                                    for (var i = 0; i <= 8; i++) {
                                        Severity: Minor
                                        Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                                          Consider simplifying this complex logical expression.
                                          Open

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

                                            Function dragHandler has 32 lines of code (exceeds 25 allowed). Consider refactoring.
                                            Open

                                                    dragHandler: function (e) {
                                                        if (!hs.dragArgs) return true;
                                                        if (!e) e = window.event;
                                                        var a = hs.dragArgs, exp = a.exp;
                                                        if (exp.iframe) {
                                            Severity: Minor
                                            Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

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

                                                      focusTopmost: function () {
                                                          var topZ = 0,
                                                              topmostKey = -1,
                                                              expanders = hs.expanders,
                                                              exp,
                                              Severity: Minor
                                              Found in assets/images/js/highslide/highslide-with-html.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 calcExpanded has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
                                              Open

                                                      calcExpanded: function () {
                                                          var exp = this.exp;
                                                          this.justify = 'auto';
                                              
                                              
                                              
                                              Severity: Minor
                                              Found in assets/images/js/highslide/highslide-with-html.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 setPosition has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
                                              Open

                                                      setPosition: function (pos, offset, vis, dur, easing) {
                                                          var exp = this.exp,
                                                              stl = exp.wrapper.style,
                                                              offset = offset || 0,
                                                              pos = pos || {
                                              Severity: Minor
                                              Found in assets/images/js/highslide/highslide-with-html.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 sizeOverlayBox has 31 lines of code (exceeds 25 allowed). Consider refactoring.
                                              Open

                                                      sizeOverlayBox: function (doWrapper, doPanels) {
                                                          var overlayBox = this.overlayBox,
                                                              x = this.x,
                                                              y = this.y;
                                                          hs.setStyles(overlayBox, {
                                              Severity: Minor
                                              Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                                                Function Outline has 31 lines of code (exceeds 25 allowed). Consider refactoring.
                                                Open

                                                    hs.Outline = function (outlineType, onLoad) {
                                                        this.onLoad = onLoad;
                                                        this.outlineType = outlineType;
                                                        var v = hs.uaVersion, tr;
                                                
                                                
                                                Severity: Minor
                                                Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                                                  Function justify has 31 lines of code (exceeds 25 allowed). Consider refactoring.
                                                  Open

                                                          justify: function (p, moveOnly) {
                                                              var tgtArr, tgt = p.target, dim = p == this.x ? 'x' : 'y';
                                                  
                                                              var hasMovedMin = false;
                                                  
                                                  
                                                  Severity: Minor
                                                  Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                                                    Function writeExtendedContent has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                                                    Open

                                                            writeExtendedContent: function () {
                                                                if (this.hasExtendedContent) return;
                                                                var exp = this;
                                                                this.body = hs.getElementByClass(this.innerContent, 'DIV', 'highslide-body');
                                                                if (this.objectType == 'iframe') {
                                                    Severity: Minor
                                                    Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

                                                      Function animate has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              animate: function (el, prop, opt) {
                                                                  var start,
                                                                      end,
                                                                      unit;
                                                                  if (typeof opt != 'object' || opt === null) {
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.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 imageCreate has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              imageCreate: function () {
                                                                  var exp = this;
                                                      
                                                                  var img = document.createElement('img');
                                                                  this.content = img;
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.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 setStyles has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              setStyles: function (el, styles) {
                                                                  for (var x in styles) {
                                                                      if (hs.ieLt9 && x == 'opacity') {
                                                                          if (styles[x] > 0.99) el.style.removeAttribute('filter');
                                                                          else el.style.filter = 'alpha(opacity=' + (styles[x] * 100) + ')';
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.js - About 55 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 replaceLang has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              replaceLang: function (s) {
                                                                  s = s.replace(/\s/g, ' ');
                                                                  var re = /{hs\.lang\.([^}]+)\}/g,
                                                                      matches = s.match(re),
                                                                      lang;
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.js - About 55 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 resize has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              resize: function (e) {
                                                                  var w, h, r = e.width / e.height;
                                                                  w = Math.max(e.width + e.dX, Math.min(this.minWidth, this.x.full));
                                                                  if (this.isImage && Math.abs(w - this.x.full) < 12) w = this.x.full;
                                                                  h = this.isHtml ? e.height + e.dY : w / r;
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.js - About 55 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 close has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              close: function () {
                                                                  if (this.isClosing || !this.isExpanded) return;
                                                                  this.isClosing = true;
                                                      
                                                                  hs.removeEventListener(document, window.opera ? 'keypress' : 'keydown', hs.keyHandler);
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.js - About 55 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 transit has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              transit: function (adj, exp) {
                                                                  var last = exp || hs.getExpander();
                                                                  exp = last;
                                                                  if (hs.upcoming) return false;
                                                                  else hs.last = last;
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.js - About 55 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 getAnchorIndex has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              getAnchorIndex: function () {
                                                                  var arr = hs.getAnchors().groups[this.slideshowGroup || 'none'];
                                                                  if (arr) for (var i = 0; i < arr.length; i++) {
                                                                      if (arr[i] == this.a) return i;
                                                                  }
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.js - About 55 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 genOverlayBox has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              genOverlayBox: function () {
                                                                  if (!this.overlayBox) this.overlayBox = hs.createElement(
                                                                      'div', {
                                                                          className: this.wrapperClassName
                                                                      }, {
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.js - About 55 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 doFullExpand has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              doFullExpand: function () {
                                                                  try {
                                                                      if (this.fullExpandLabel) hs.discardElement(this.fullExpandLabel);
                                                      
                                                                      this.focus();
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.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 showOverlays has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              showOverlays: function () {
                                                                  var b = this.overlayBox;
                                                                  b.className = '';
                                                                  hs.setStyles(b, {
                                                                      top: (this.y.p1 + this.y.cb) + 'px',
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.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 createElement has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              createElement: function (tag, attribs, styles, parent, nopad) {
                                                                  var el = document.createElement(tag);
                                                                  if (attribs) hs.extend(el, attribs);
                                                                  if (nopad) hs.setStyles(el, {padding: 0, border: 'none', margin: 0});
                                                                  if (styles) hs.setStyles(el, styles);
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.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 afterClose has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              afterClose: function () {
                                                                  this.a.className = this.a.className.replace('highslide-active-anchor', '');
                                                      
                                                                  this.doShowHide('visible');
                                                      
                                                      
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.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 addEventListener has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              addEventListener: function (el, event, func) {
                                                                  if (el == document && event == 'ready') {
                                                                      hs.push(hs.onReady, func);
                                                                  }
                                                                  try {
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.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 setObjContainerSize has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              setObjContainerSize: function (parent, auto) {
                                                                  var c = hs.getElementByClass(parent, 'DIV', 'highslide-body');
                                                                  if (/(iframe|swf)/.test(this.objectType)) {
                                                                      if (this.objectWidth) c.style.width = this.objectWidth + 'px';
                                                                      if (this.objectHeight) c.style.height = this.objectHeight + 'px';
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.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 preloadImages has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              preloadImages: function (number) {
                                                                  if (number && typeof number != 'object') hs.numberOfImagesToPreload = number;
                                                      
                                                                  var arr = hs.getAnchors();
                                                                  for (var i = 0; i < arr.images.length && i < hs.numberOfImagesToPreload; i++) {
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.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 correctIframeSize has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                                                      Open

                                                              correctIframeSize: function () {
                                                                  var wDiff = this.innerContent.offsetWidth - this.ruler.offsetWidth;
                                                                  hs.discardElement(this.ruler);
                                                                  if (wDiff < 0) wDiff = 0;
                                                      
                                                      
                                                      Severity: Minor
                                                      Found in assets/images/js/highslide/highslide-with-html.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

                                                                          } else if (visibility == 'hidden') { // hide if behind
                                                                              var elPos = hs.getPosition(els[i]);
                                                                              elPos.w = els[i].offsetWidth;
                                                                              elPos.h = els[i].offsetHeight;
                                                      
                                                      
                                                      Severity: Major
                                                      Found in assets/images/js/highslide/highslide-with-html.js - About 45 mins to fix

                                                        Avoid deeply nested control flow statements.
                                                        Open

                                                                                if (!groups[g]) groups[g] = [];
                                                        Severity: Major
                                                        Found in assets/images/js/highslide/highslide-with-html.js - About 45 mins to fix

                                                          Avoid deeply nested control flow statements.
                                                          Open

                                                                                  if (ie6) {
                                                                                      o.style.width = (overlayBox.offsetWidth + 2 * x.cb
                                                                                          + x.p1 + x.p2) + 'px';
                                                                                  }
                                                          Severity: Major
                                                          Found in assets/images/js/highslide/highslide-with-html.js - About 45 mins to fix

                                                            Avoid deeply nested control flow statements.
                                                            Open

                                                                                    if (re[0] == 'hs.expand') hs.push(images, el);
                                                                                    else if (re[0] == 'hs.htmlExpand') hs.push(htmls, el);
                                                            Severity: Major
                                                            Found in assets/images/js/highslide/highslide-with-html.js - About 45 mins to fix

                                                              Avoid deeply nested control flow statements.
                                                              Open

                                                                                  if (!hasDragged && !hs.hasFocused && !/(move|resize)/.test(hs.dragArgs.type)) {
                                                                                      exp.close();
                                                                                  }
                                                                                  else if (hasDragged || (!hasDragged && hs.hasHtmlExpanders)) {
                                                                                      hs.dragArgs.exp.doShowHide('hidden');
                                                              Severity: Major
                                                              Found in assets/images/js/highslide/highslide-with-html.js - About 45 mins to fix

                                                                Avoid deeply nested control flow statements.
                                                                Open

                                                                                    if (hs.dragArgs.exp.releaseMask)
                                                                                        hs.dragArgs.exp.releaseMask.style.display = 'none';
                                                                Severity: Major
                                                                Found in assets/images/js/highslide/highslide-with-html.js - About 45 mins to fix

                                                                  Avoid deeply nested control flow statements.
                                                                  Open

                                                                                          while (next && !hs.isHsAnchor(next)) {
                                                                                              if ((new RegExp('highslide-' + type)).test(next.className || null)) {
                                                                                                  if (!next.id) this.a['_' + type + 'Id'] = next.id = 'hsId' + hs.idCounter++;
                                                                                                  this[type] = hs.getNode(next.id);
                                                                                                  break;
                                                                  Severity: Major
                                                                  Found in assets/images/js/highslide/highslide-with-html.js - About 45 mins to fix

                                                                    Avoid deeply nested control flow statements.
                                                                    Open

                                                                                            if (!hiddenBy) els[i].style[prop] = els[i].origProp;
                                                                    Severity: Major
                                                                    Found in assets/images/js/highslide/highslide-with-html.js - About 45 mins to fix

                                                                      Avoid deeply nested control flow statements.
                                                                      Open

                                                                                      } else if (/highslide-image-blur/.test(el.className)) {
                                                                                          el.style.cursor = hs.styleRestoreCursor;
                                                                                      }
                                                                      Severity: Major
                                                                      Found in assets/images/js/highslide/highslide-with-html.js - About 45 mins to fix

                                                                        Avoid deeply nested control flow statements.
                                                                        Open

                                                                                            if (hs.styleRestoreCursor && hs.dragArgs.type == 'image')
                                                                                                hs.dragArgs.exp.content.style.cursor = hs.styleRestoreCursor;
                                                                        Severity: Major
                                                                        Found in assets/images/js/highslide/highslide-with-html.js - About 45 mins to fix

                                                                          Avoid deeply nested control flow statements.
                                                                          Open

                                                                                                  for (var key = 0; key < hs.expanders.length; key++) {
                                                                                                      var exp = hs.expanders[key];
                                                                                                      if (exp && exp.a == el) return key;
                                                                                                  }
                                                                          Severity: Major
                                                                          Found in assets/images/js/highslide/highslide-with-html.js - About 45 mins to fix

                                                                            Consider simplifying this complex logical expression.
                                                                            Open

                                                                                            if ((!tId && !sg) || (tId && tId == this.thumbsUserSetId)
                                                                                                || (sg && sg === this.slideshowGroup)) {
                                                                                                if (this.isImage || (this.isHtml && o.useOnHtml))
                                                                                                    this.createOverlay(o);
                                                                                            }
                                                                            Severity: Major
                                                                            Found in assets/images/js/highslide/highslide-with-html.js - About 40 mins to fix

                                                                              Function setPosition has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                              Open

                                                                                      setPosition: function (pos, offset, vis, dur, easing) {
                                                                              Severity: Minor
                                                                              Found in assets/images/js/highslide/highslide-with-html.js - About 35 mins to fix

                                                                                Function createElement has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                Open

                                                                                        createElement: function (tag, attribs, styles, parent, nopad) {
                                                                                Severity: Minor
                                                                                Found in assets/images/js/highslide/highslide-with-html.js - About 35 mins to fix

                                                                                  Function getExpander has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                                                                                  Open

                                                                                          getExpander: function (el, expOnly) {
                                                                                              if (typeof el == 'undefined') return hs.expanders[hs.focusKey] || null;
                                                                                              if (typeof el == 'number') return hs.expanders[el] || null;
                                                                                              if (typeof el == 'string') el = hs.$(el);
                                                                                              return hs.expanders[hs.getWrapperKey(el, expOnly)] || null;
                                                                                  Severity: Minor
                                                                                  Found in assets/images/js/highslide/highslide-with-html.js - About 35 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 getParam has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                                                                                  Open

                                                                                          getParam: function (a, param) {
                                                                                              a.getParams = a.onclick;
                                                                                              var p = a.getParams ? a.getParams() : null;
                                                                                              a.getParams = null;
                                                                                  
                                                                                  
                                                                                  Severity: Minor
                                                                                  Found in assets/images/js/highslide/highslide-with-html.js - About 35 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 htmlGetSize has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                                                                                  Open

                                                                                          htmlGetSize: function () {
                                                                                              if (this.iframe && !this.objectHeight) { // loadtime before
                                                                                                  this.iframe.style.height = this.body.style.height = this.getIframePageHeight() + 'px';
                                                                                              }
                                                                                              this.innerContent.appendChild(hs.clearing);
                                                                                  Severity: Minor
                                                                                  Found in assets/images/js/highslide/highslide-with-html.js - About 35 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 destroyObject has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                                                                                  Open

                                                                                          destroyObject: function () {
                                                                                              if (hs.ie && this.iframe)
                                                                                                  try {
                                                                                                      this.iframe.contentWindow.document.body.innerHTML = '';
                                                                                                  } catch (e) {
                                                                                  Severity: Minor
                                                                                  Found in assets/images/js/highslide/highslide-with-html.js - About 35 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 too many return statements within this function.
                                                                                  Open

                                                                                              return true;
                                                                                  Severity: Major
                                                                                  Found in assets/images/js/highslide/highslide-with-html.js - About 30 mins to fix

                                                                                    Avoid too many return statements within this function.
                                                                                    Open

                                                                                                return false;
                                                                                    Severity: Major
                                                                                    Found in assets/images/js/highslide/highslide-with-html.js - About 30 mins to fix

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

                                                                                          hs.Dimension = function (exp, dim) {
                                                                                              this.exp = exp;
                                                                                              this.dim = dim;
                                                                                              this.ucwh = dim == 'x' ? 'Width' : 'Height';
                                                                                              this.wh = this.ucwh.toLowerCase();
                                                                                      Severity: Minor
                                                                                      Found in assets/images/js/highslide/highslide-with-html.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

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

                                                                                              getPosition: function (el) {
                                                                                                  var p = {x: el.offsetLeft, y: el.offsetTop};
                                                                                                  while (el.offsetParent) {
                                                                                                      el = el.offsetParent;
                                                                                                      p.x += el.offsetLeft;
                                                                                      Severity: Minor
                                                                                      Found in assets/images/js/highslide/highslide-with-html.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

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

                                                                                              doShowHide: function (visibility) {
                                                                                                  if (hs.hideSelects) this.showHideElements('SELECT', visibility);
                                                                                                  if (hs.hideIframes) this.showHideElements('IFRAME', visibility);
                                                                                                  if (hs.geckoMac) this.showHideElements('*', visibility);
                                                                                              },
                                                                                      Severity: Minor
                                                                                      Found in assets/images/js/highslide/highslide-with-html.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 4 locations. Consider refactoring.
                                                                                      Open

                                                                                          hs.Outline.prototype = {
                                                                                              preloadGraphic: function () {
                                                                                                  var src = hs.graphicsDir + (hs.outlinesDir || "outlines/") + this.outlineType + ".png";
                                                                                      
                                                                                                  var appendTo = hs.safari && hs.uaVersion < 525 ? hs.container : null;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 wk to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1149..1240
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 969..1060
                                                                                      assets/images/js/highslide/highslide.js on lines 796..887

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

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                          hs.Ajax.prototype = {
                                                                                              run: function () {
                                                                                                  var xhr;
                                                                                                  if (!this.src) this.src = hs.getSrc(this.a);
                                                                                                  if (this.src.match('#')) {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 6 days to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 3007..3104

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

                                                                                      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

                                                                                              htmlSizeOperations: function () {
                                                                                      
                                                                                                  this.setObjContainerSize(this.innerContent);
                                                                                      
                                                                                      
                                                                                      
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 5 days to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1779..1835

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

                                                                                      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

                                                                                              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/images/js/highslide/highslide-with-html.js and 1 other location - About 5 days to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1650..1713

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

                                                                                      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

                                                                                              showHideElements: function (tagName, visibility) {
                                                                                                  var els = document.getElementsByTagName(tagName);
                                                                                                  var prop = tagName == '*' ? 'overflow' : 'visibility';
                                                                                                  for (var i = 0; i < els.length; i++) {
                                                                                                      if (prop == 'visibility' || (document.defaultView.getComputedStyle(
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 5 days to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1488..1531

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

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

                                                                                          hs.fx.prototype = {
                                                                                              update: function () {
                                                                                                  (hs.fx.step[this.prop] || hs.fx.step._default)(this);
                                                                                      
                                                                                                  if (this.options.step)
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 4 days to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1024..1090
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 844..910
                                                                                      assets/images/js/highslide/highslide.js on lines 671..737

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

                                                                                      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

                                                                                              getInline: function (types, addOverlay) {
                                                                                                  for (var i = 0; i < types.length; i++) {
                                                                                                      var type = types[i], s = null;
                                                                                                      if (!this[type + 'Id'] && this.thumbsUserSetId)
                                                                                                          this[type + 'Id'] = type + '-for-' + this.thumbsUserSetId;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 3 days to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1441..1479

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

                                                                                      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

                                                                                              writeExtendedContent: function () {
                                                                                                  if (this.hasExtendedContent) return;
                                                                                                  var exp = this;
                                                                                                  this.body = hs.getElementByClass(this.innerContent, 'DIV', 'highslide-body');
                                                                                                  if (this.objectType == 'iframe') {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 3 days to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1692..1724

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

                                                                                      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

                                                                                              justify: function (p, moveOnly) {
                                                                                                  var tgtArr, tgt = p.target, dim = p == this.x ? 'x' : 'y';
                                                                                      
                                                                                                  var hasMovedMin = false;
                                                                                      
                                                                                      
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 3 days to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1187..1226

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

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

                                                                                              correctRatio: function (ratio) {
                                                                                                  var x = this.x,
                                                                                                      y = this.y,
                                                                                                      changed = false,
                                                                                                      xSize = Math.min(x.full, x.size),
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 3 days to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1923..1971
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1464..1512
                                                                                      assets/images/js/highslide/highslide.js on lines 1228..1276

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

                                                                                      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

                                                                                              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: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 2 days to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1610..1649

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

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

                                                                                              sizeOverlayBox: function (doWrapper, doPanels) {
                                                                                                  var overlayBox = this.overlayBox,
                                                                                                      x = this.x,
                                                                                                      y = this.y;
                                                                                                  hs.setStyles(overlayBox, {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 days to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2854..2886
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 2269..2301
                                                                                      assets/images/js/highslide/highslide.js on lines 1752..1784

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

                                                                                      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

                                                                                              calcExpanded: function () {
                                                                                                  var exp = this.exp;
                                                                                                  this.justify = 'auto';
                                                                                      
                                                                                      
                                                                                      
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 2 days to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 936..958

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

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

                                                                                          hs.Outline = function (outlineType, onLoad) {
                                                                                              this.onLoad = onLoad;
                                                                                              this.outlineType = outlineType;
                                                                                              var v = hs.uaVersion, tr;
                                                                                      
                                                                                      
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 days to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1111..1147
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 931..967
                                                                                      assets/images/js/highslide/highslide.js on lines 758..794

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

                                                                                      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

                                                                                              keyHandler: function (e) {
                                                                                                  if (!e) e = window.event;
                                                                                                  if (!e.target) e.target = e.srcElement; // ie
                                                                                                  if (typeof e.target.form != 'undefined') return true; // form element has focus
                                                                                                  var exp = hs.getExpander();
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 2 days to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 315..358

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

                                                                                      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

                                                                                              wrapperMouseHandler: function (e) {
                                                                                                  try {
                                                                                                      if (!e) e = window.event;
                                                                                                      var over = /mouseover/i.test(e.type);
                                                                                                      if (!e.target) e.target = e.srcElement; // ie
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 2 other locations - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 656..676
                                                                                      assets/images/js/highslide/highslide.js on lines 492..512

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

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                                  hs.animate(this.wrapper, to.wrapper, {
                                                                                                      duration: dur,
                                                                                                      easing: easing,
                                                                                                      step: function (val, args) {
                                                                                                          if (exp.outline && exp.outlineWhileAnimating && args.prop == 'top') {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2073..2094

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

                                                                                      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

                                                                                              correctIframeSize: function () {
                                                                                                  var wDiff = this.innerContent.offsetWidth - this.ruler.offsetWidth;
                                                                                                  hs.discardElement(this.ruler);
                                                                                                  if (wDiff < 0) wDiff = 0;
                                                                                      
                                                                                      
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1756..1778

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

                                                                                      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

                                                                                              htmlGetSize: function () {
                                                                                                  if (this.iframe && !this.objectHeight) { // loadtime before
                                                                                                      this.iframe.style.height = this.body.style.height = this.getIframePageHeight() + 'px';
                                                                                                  }
                                                                                                  this.innerContent.appendChild(hs.clearing);
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1725..1739

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

                                                                                      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

                                                                                              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: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 983..1004

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

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

                                                                                              showOverlays: function () {
                                                                                                  var b = this.overlayBox;
                                                                                                  b.className = '';
                                                                                                  hs.setStyles(b, {
                                                                                                      top: (this.y.p1 + this.y.cb) + 'px',
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2888..2907
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 2303..2322
                                                                                      assets/images/js/highslide/highslide.js on lines 1786..1805

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

                                                                                      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

                                                                                              get: function (key) {
                                                                                                  switch (key) {
                                                                                                      case 'loadingPos':
                                                                                                          return this.tpos + this.tb + (this.t - hs.loading['offset' + this.ucwh]) / 2;
                                                                                                      case 'wsize':
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 901..919

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

                                                                                      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 (exp && e.type == 'mousedown') {
                                                                                                      if (e.target.form) return true;
                                                                                                      var match = el.className.match(/highslide-(image|move|resize)/);
                                                                                                      if (match) {
                                                                                                          hs.dragArgs = {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 730..786

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

                                                                                      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

                                                                                              htmlPrepareClose: function () {
                                                                                                  if (hs.geckoMac) { // bad redraws
                                                                                                      if (!hs.mask) hs.mask = hs.createElement('div', null,
                                                                                                          {position: 'absolute'}, hs.container);
                                                                                                      hs.setStyles(hs.mask, {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2623..2640

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

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                          hs.addEventListener(document, 'ready', function () {
                                                                                              if (hs.expandCursor) {
                                                                                                  var style = hs.createElement('style', {type: 'text/css'}, null,
                                                                                                      document.getElementsByTagName('HEAD')[0]),
                                                                                                      backCompat = document.compatMode == 'BackCompat';
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1885..1909

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

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

                                                                                              imageCreate: function () {
                                                                                                  var exp = this;
                                                                                      
                                                                                                  var img = document.createElement('img');
                                                                                                  this.content = img;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1501..1526
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1301..1326
                                                                                      assets/images/js/highslide/highslide.js on lines 1105..1130

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

                                                                                      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

                                                                                              doFullExpand: function () {
                                                                                                  try {
                                                                                                      if (this.fullExpandLabel) hs.discardElement(this.fullExpandLabel);
                                                                                      
                                                                                                      this.focus();
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 2 other locations - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 2359..2380
                                                                                      assets/images/js/highslide/highslide.js on lines 1830..1851

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

                                                                                      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

                                                                                              resize: function (e) {
                                                                                                  var w, h, r = e.width / e.height;
                                                                                                  w = Math.max(e.width + e.dX, Math.min(this.minWidth, this.x.full));
                                                                                                  if (this.isImage && Math.abs(w - this.x.full) < 12) w = this.x.full;
                                                                                                  h = this.isHtml ? e.height + e.dY : w / r;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2570..2580

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

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

                                                                                              animate: function (el, prop, opt) {
                                                                                                  var start,
                                                                                                      end,
                                                                                                      unit;
                                                                                                  if (typeof opt != 'object' || opt === null) {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 253..277
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 207..231
                                                                                      assets/images/js/highslide/highslide.js on lines 142..166

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

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

                                                                                              calcThumb: function () {
                                                                                                  this.t = this.exp.el[this.wh] ? parseInt(this.exp.el[this.wh]) :
                                                                                                      this.exp.el['offset' + this.ucwh];
                                                                                                  this.tpos = this.exp.tpos[this.dim];
                                                                                                  this.tb = (this.exp.el['offset' + this.ucwh] - this.t) / 2;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1281..1290
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1101..1110
                                                                                      assets/images/js/highslide/highslide.js on lines 926..935

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

                                                                                      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

                                                                                              getWrapperKey: function (element, expOnly) {
                                                                                                  var el, re = /^highslide-wrapper-([0-9]+)$/;
                                                                                                  // 1. look in open expanders
                                                                                                  el = element;
                                                                                                  while (el.parentNode) {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 366..388

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

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

                                                                                              preloadImages: function (number) {
                                                                                                  if (number && typeof number != 'object') hs.numberOfImagesToPreload = number;
                                                                                      
                                                                                                  var arr = hs.getAnchors();
                                                                                                  for (var i = 0; i < arr.images.length && i < hs.numberOfImagesToPreload; i++) {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 890..908
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 715..733
                                                                                      assets/images/js/highslide/highslide.js on lines 551..569

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

                                                                                      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

                                                                                                  try {
                                                                                                      if (this.isHtml) this.htmlPrepareClose();
                                                                                                      this.content.style.cursor = 'default';
                                                                                                      this.changeSize(
                                                                                                          0, {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2599..2620

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

                                                                                      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

                                                                                              expand: function (a, params, custom, type) {
                                                                                                  if (!a) a = hs.createElement('a', null, {display: 'none'}, hs.container);
                                                                                                  if (typeof a.getParams == 'function') return params;
                                                                                                  if (type == 'html') {
                                                                                                      for (var i = 0; i < hs.sleeping.length; i++) {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 339..358

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

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                                  if (this.objectType == 'ajax' && !hs.getCacheBinding(this.a)) {
                                                                                                      this.showLoading();
                                                                                                      var exp = this;
                                                                                                      var ajax = new hs.Ajax(this.a, innerContent);
                                                                                                      ajax.src = this.src;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1582..1599

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

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

                                                                                              getPageSize: function () {
                                                                                                  var d = document, w = window, iebody = d.compatMode && d.compatMode != 'BackCompat'
                                                                                                          ? d.documentElement : d.body,
                                                                                                      ieLt9 = hs.ie && (hs.uaVersion < 9 || typeof pageXOffset == 'undefined');
                                                                                      
                                                                                      
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 298..313
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 252..267
                                                                                      assets/images/js/highslide/highslide.js on lines 187..202

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

                                                                                      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

                                                                                              show: function () {
                                                                                                  var x = this.x, y = this.y;
                                                                                                  this.doShowHide('hidden');
                                                                                      
                                                                                                  // Apply size change
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 day to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1291..1313

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

                                                                                      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

                                                                                              getIframePageHeight: function () {
                                                                                                  var h;
                                                                                                  try {
                                                                                                      var doc = this.iDoc = this.iframe.contentDocument || this.iframe.contentWindow.document;
                                                                                                      var clearing = doc.createElement('div');
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 7 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1741..1755

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

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

                                                                                          hs.Dimension = function (exp, dim) {
                                                                                              this.exp = exp;
                                                                                              this.dim = dim;
                                                                                              this.ucwh = dim == 'x' ? 'Width' : 'Height';
                                                                                              this.wh = this.ucwh.toLowerCase();
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 7 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1242..1252
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1062..1072
                                                                                      assets/images/js/highslide/highslide.js on lines 889..899

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

                                                                                      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

                                                                                              showLoading: function () {
                                                                                                  if (this.onLoadStarted || this.loading) return;
                                                                                      
                                                                                                  this.loading = hs.loading;
                                                                                                  var exp = this;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 7 hrs to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1088..1103

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

                                                                                      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 (exp.iframe) {
                                                                                                      if (!exp.releaseMask) exp.releaseMask = hs.createElement('div', null,
                                                                                                          {
                                                                                                              position: 'absolute',
                                                                                                              width: exp.x.size + 'px',
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 7 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 794..809

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

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

                                                                                              css: function (el, prop) {
                                                                                                  if (el.style[prop]) {
                                                                                                      return el.style[prop];
                                                                                                  } else if (document.defaultView) {
                                                                                                      return document.defaultView.getComputedStyle(el, null).getPropertyValue(prop);
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 7 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 278..296
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 232..250
                                                                                      assets/images/js/highslide/highslide.js on lines 167..185

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

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

                                                                                          hs.extend(hs.fx, {
                                                                                              step: {
                                                                                      
                                                                                                  opacity: function (fx) {
                                                                                                      hs.setStyles(fx.elem, {opacity: fx.now});
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 7 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1092..1109
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 912..929
                                                                                      assets/images/js/highslide/highslide.js on lines 739..756

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

                                                                                      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

                                                                                              preloadAjaxElement: function (i) {
                                                                                                  if (!hs.preloadTheseAjax[i]) return;
                                                                                                  var a = hs.preloadTheseAjax[i];
                                                                                                  var cache = hs.getNode(hs.getParam(a, 'contentId'));
                                                                                                  if (!cache) cache = hs.getSelfRendered();
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 7 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 442..455

                                                                                      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

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

                                                                                                  if (exp.isHtml) {
                                                                                                      var d = exp.scrollerDiv;
                                                                                                      if (this.sizeDiff === undefined)
                                                                                                          this.sizeDiff = exp.innerContent['offset' + this.ucwh] - d['offset' + this.ucwh];
                                                                                                      d.style[this.wh] = (this.size - this.sizeDiff) + 'px';
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 6 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1337..1345

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

                                                                                      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

                                                                                              fitOverlayBox: function (ratio, changed) {
                                                                                                  var x = this.x, y = this.y;
                                                                                                  if (this.overlayBox && (this.isImage || this.allowHeightReduction)) {
                                                                                                      while (y.size > this.minHeight && x.size > this.minWidth
                                                                                                      && y.get('wsize') > y.get('fitsize')) {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 6 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1972..1984

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

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

                                                                                              focusTopmost: function () {
                                                                                                  var topZ = 0,
                                                                                                      topmostKey = -1,
                                                                                                      expanders = hs.expanders,
                                                                                                      exp,
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 6 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 457..475
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 315..333
                                                                                      assets/images/js/highslide/highslide.js on lines 230..248

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

                                                                                      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

                                                                                              transit: function (adj, exp) {
                                                                                                  var last = exp || hs.getExpander();
                                                                                                  exp = last;
                                                                                                  if (hs.upcoming) return false;
                                                                                                  else hs.last = last;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 6 hrs to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 282..299

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

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

                                                                                              genOverlayBox: function () {
                                                                                                  if (!this.overlayBox) this.overlayBox = hs.createElement(
                                                                                                      'div', {
                                                                                                          className: this.wrapperClassName
                                                                                                      }, {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 6 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2837..2853
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 2252..2268
                                                                                      assets/images/js/highslide/highslide.js on lines 1735..1751

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

                                                                                      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 (this.iframe) {
                                                                                                      try {
                                                                                                          var exp = this,
                                                                                                              doc = this.iframe.contentDocument || this.iframe.contentWindow.document;
                                                                                                          hs.addEventListener(doc, 'mousedown', function () {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 6 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2309..2320

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

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                              if (!this.outlineType) {
                                                                                                  this[this.contentType + 'Create']();
                                                                                      
                                                                                              } else if (hs.pendingOutlines[this.outlineType]) {
                                                                                                  this.connectOutline();
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 5 hrs to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1055..1071

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

                                                                                      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

                                                                                              replaceLang: function (s) {
                                                                                                  s = s.replace(/\s/g, ' ');
                                                                                                  var re = /{hs\.lang\.([^}]+)\}/g,
                                                                                                      matches = s.match(re),
                                                                                                      lang;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 2 other locations - About 5 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 379..389
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 302..312

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

                                                                                      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

                                                                                              getPosition: function (el) {
                                                                                                  var p = {x: el.offsetLeft, y: el.offsetTop};
                                                                                                  while (el.offsetParent) {
                                                                                                      el = el.offsetParent;
                                                                                                      p.x += el.offsetLeft;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 2 other locations - About 5 hrs to fix
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 269..281
                                                                                      assets/images/js/highslide/highslide.js on lines 204..216

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

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                                      if (this.isImage) {
                                                                                                          x.full = this.content.width;
                                                                                                          y.full = this.content.height;
                                                                                      
                                                                                                          hs.setStyles(this.content, {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 5 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1616..1626

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

                                                                                      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

                                                                                                  for (var i = 0; i < hs.overlays.length; i++) {
                                                                                                      var o = hs.overlays[i], tId = o.thumbnailId, sg = o.slideshowGroup;
                                                                                                      if ((!tId && !sg) || (tId && tId == this.thumbsUserSetId)
                                                                                                          || (sg && sg === this.slideshowGroup)) {
                                                                                                          if (this.isImage || (this.isHtml && o.useOnHtml))
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 5 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2820..2827

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

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                                  if (this.isImage) {
                                                                                                      this.content.title = hs.lang.restoreTitle;
                                                                                      
                                                                                                      if (hs.restoreCursor) {
                                                                                                          hs.styleRestoreCursor = window.opera ? 'pointer' : 'url(' + hs.graphicsDir + hs.restoreCursor + '), pointer';
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 5 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2553..2561

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

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

                                                                                              addEventListener: function (el, event, func) {
                                                                                                  if (el == document && event == 'ready') {
                                                                                                      hs.push(hs.onReady, func);
                                                                                                  }
                                                                                                  try {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 5 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 852..866
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 677..691
                                                                                      assets/images/js/highslide/highslide.js on lines 513..527

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

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

                                                                                              getNode: function (id) {
                                                                                                  var node = hs.$(id), clone = hs.clones[id], a = {};
                                                                                                  if (!node && !clone) return null;
                                                                                                  if (!clone) {
                                                                                                      clone = node.cloneNode(true);
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 4 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 492..503
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 350..361
                                                                                      assets/images/js/highslide/highslide.js on lines 265..276

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

                                                                                      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

                                                                                              preloadAjax: function (e) {
                                                                                                  var arr = hs.getAnchors();
                                                                                                  for (var i = 0; i < arr.htmls.length; i++) {
                                                                                                      var a = arr.htmls[i];
                                                                                                      if (hs.getParam(a, 'objectType') == 'ajax' && hs.getParam(a, 'cacheAjax'))
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 4 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 431..440

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

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

                                                                                              setStyles: function (el, styles) {
                                                                                                  for (var x in styles) {
                                                                                                      if (hs.ieLt9 && x == 'opacity') {
                                                                                                          if (styles[x] > 0.99) el.style.removeAttribute('filter');
                                                                                                          else el.style.filter = 'alpha(opacity=' + (styles[x] * 100) + ')';
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 4 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 244..252
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 198..206
                                                                                      assets/images/js/highslide/highslide.js on lines 133..141

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

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

                                                                                              preloadFullImage: function (i) {
                                                                                                  if (hs.continuePreloading && hs.preloadTheseImages[i] && hs.preloadTheseImages[i] != 'undefined') {
                                                                                                      var img = document.createElement('img');
                                                                                                      img.onload = function () {
                                                                                                          img = null;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 4 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 880..889
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 705..714
                                                                                      assets/images/js/highslide/highslide.js on lines 541..550

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

                                                                                      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

                                                                                              getCacheBinding: function (a) {
                                                                                                  for (var i = 0; i < hs.cacheBindings.length; i++) {
                                                                                                      if (hs.cacheBindings[i][0] == a) {
                                                                                                          var c = hs.cacheBindings[i][1];
                                                                                                          hs.cacheBindings[i][1] = c.cloneNode(1);
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 4 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 420..429

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

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

                                                                                              getExpander: function (el, expOnly) {
                                                                                                  if (typeof el == 'undefined') return hs.expanders[hs.focusKey] || null;
                                                                                                  if (typeof el == 'number') return hs.expanders[el] || null;
                                                                                                  if (typeof el == 'string') el = hs.$(el);
                                                                                                  return hs.expanders[hs.getWrapperKey(el, expOnly)] || null;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 4 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 698..703
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 554..559
                                                                                      assets/images/js/highslide/highslide.js on lines 390..395

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

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

                                                                                              if (!hs.allowMultipleInstances && !hs.upcoming) {
                                                                                                  if (hs.expanders[key - 1]) hs.expanders[key - 1].close();
                                                                                                  if (typeof hs.focusKey != 'undefined' && hs.expanders[hs.focusKey])
                                                                                                      hs.expanders[hs.focusKey].close();
                                                                                              }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 4 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1410..1414
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1214..1218
                                                                                      assets/images/js/highslide/highslide.js on lines 1026..1030

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

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

                                                                                              if (!hs.allowSimultaneousLoading) for (var i = 0; i < hs.expanders.length; i++) {
                                                                                                  if (hs.expanders[i] && hs.expanders[i].thumb != el && !hs.expanders[i].onLoadStarted) {
                                                                                                      hs.expanders[i].cancelLoading();
                                                                                                  }
                                                                                              }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1404..1408
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1208..1212
                                                                                      assets/images/js/highslide/highslide.js on lines 1020..1024

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

                                                                                      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

                                                                                              writeCredits: function () {
                                                                                                  this.credits = hs.createElement('a', {
                                                                                                      href: hs.creditsHref,
                                                                                                      target: hs.creditsTarget,
                                                                                                      className: 'highslide-credits',
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1427..1439

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

                                                                                      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

                                                                                              destroyObject: function () {
                                                                                                  if (hs.ie && this.iframe)
                                                                                                      try {
                                                                                                          this.iframe.contentWindow.document.body.innerHTML = '';
                                                                                                      } catch (e) {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2642..2650

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

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

                                                                                                  if (exp.isImage && (exp.useBox || hs.padToMinWidth)) {
                                                                                                      this.imgSize = i;
                                                                                                      this.size = Math.max(this.size, this.imgSize);
                                                                                                      exp.content.style[this.lt] = this.get('imgPad') + 'px';
                                                                                                  } else
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1322..1327
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1142..1147
                                                                                      assets/images/js/highslide/highslide.js on lines 961..966

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

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

                                                                                              createElement: function (tag, attribs, styles, parent, nopad) {
                                                                                                  var el = document.createElement(tag);
                                                                                                  if (attribs) hs.extend(el, attribs);
                                                                                                  if (nopad) hs.setStyles(el, {padding: 0, border: 'none', margin: 0});
                                                                                                  if (styles) hs.setStyles(el, styles);
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 230..237
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 184..191
                                                                                      assets/images/js/highslide/highslide.js on lines 119..126

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

                                                                                      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

                                                                                              createFullExpand: function () {
                                                                                                  this.fullExpandLabel = hs.createElement(
                                                                                                      'a', {
                                                                                                          href: 'javascript:hs.expanders[' + this.key + '].doFullExpand();',
                                                                                                          title: hs.lang.fullExpandTitle,
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1813..1828

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

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

                                                                                                      for (var x in hs.langDefaults) {
                                                                                                          if (typeof hs[x] != 'undefined') hs.lang[x] = hs[x];
                                                                                                          else if (typeof hs.lang[x] == 'undefined' && typeof hs.langDefaults[x] != 'undefined')
                                                                                                              hs.lang[x] = hs.langDefaults[x];
                                                                                                      }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 919..923
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 743..747
                                                                                      assets/images/js/highslide/highslide.js on lines 579..583

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

                                                                                      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

                                                                                              setObjContainerSize: function (parent, auto) {
                                                                                                  var c = hs.getElementByClass(parent, 'DIV', 'highslide-body');
                                                                                                  if (/(iframe|swf)/.test(this.objectType)) {
                                                                                                      if (this.objectWidth) c.style.width = this.objectWidth + 'px';
                                                                                                      if (this.objectHeight) c.style.height = this.objectHeight + 'px';
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1684..1690

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

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

                                                                                              getParam: function (a, param) {
                                                                                                  a.getParams = a.onclick;
                                                                                                  var p = a.getParams ? a.getParams() : null;
                                                                                                  a.getParams = null;
                                                                                      
                                                                                      
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 477..484
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 335..342
                                                                                      assets/images/js/highslide/highslide.js on lines 250..257

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

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

                                                                                                  this.mouseIsOver = this.x.pos < mX && mX < this.x.pos + this.x.get('wsize')
                                                                                                      && this.y.pos < mY && mY < this.y.pos + this.y.get('wsize');
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2325..2326
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1824..1825
                                                                                      assets/images/js/highslide/highslide.js on lines 1380..1381

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

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

                                                                                              connectOutline: function () {
                                                                                                  var outline = this.outline = hs.pendingOutlines[this.outlineType];
                                                                                                  outline.exp = this;
                                                                                                  outline.table.style.zIndex = this.wrapper.style.zIndex - 1;
                                                                                                  hs.pendingOutlines[this.outlineType] = null;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1467..1472
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1270..1275
                                                                                      assets/images/js/highslide/highslide.js on lines 1081..1086

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

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

                                                                                                  for (var i = 0; i < this.overlays.length; i++) {
                                                                                                      var o = hs.$('hsId' + this.overlays[i]);
                                                                                                      if (/panel$/.test(o.position)) this.positionOverlay(o);
                                                                                                      else hs.push(os, o);
                                                                                                  }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2829..2833
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 2244..2248
                                                                                      assets/images/js/highslide/highslide.js on lines 1727..1731

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

                                                                                      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

                                                                                              sleep: function () {
                                                                                                  if (this.outline) this.outline.table.style.display = 'none';
                                                                                                  this.releaseMask = null;
                                                                                                  this.wrapper.style.display = 'none';
                                                                                                  this.isExpanded = false;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 3 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2652..2658

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

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

                                                                                              getAnchorIndex: function () {
                                                                                                  var arr = hs.getAnchors().groups[this.slideshowGroup || 'none'];
                                                                                                  if (arr) for (var i = 0; i < arr.length; i++) {
                                                                                                      if (arr[i] == this.a) return i;
                                                                                                  }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2362..2368
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1860..1866
                                                                                      assets/images/js/highslide/highslide.js on lines 1412..1418

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

                                                                                      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

                                                                                              getElementByClass: function (el, tagName, className) {
                                                                                                  var els = el.getElementsByTagName(tagName);
                                                                                                  for (var i = 0; i < els.length; i++) {
                                                                                                      if ((new RegExp(className)).test(els[i].className)) {
                                                                                                          return els[i];
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 2 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 370..378
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 293..301

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

                                                                                      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

                                                                                              for (var i = 0; i < hs.expanders.length; i++) {
                                                                                                  if (hs.expanders[i] && hs.expanders[i].a == a) {
                                                                                                      hs.expanders[i].focus();
                                                                                                      return false;
                                                                                                  }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1012..1017

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

                                                                                      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 (up && this.isHtml) {
                                                                                                      hs.setStyles(this.wrapper, {
                                                                                                          left: (x.tpos - x.cb + x.tb) + 'px',
                                                                                                          top: (y.tpos - y.cb + y.tb) + 'px'
                                                                                                      });
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2063..2068

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

                                                                                      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

                                                                                                  contentWrapper: '<div class="highslide-header"><ul>' +
                                                                                                  '<li class="highslide-previous">' +
                                                                                                  '<a href="#" title="{hs.lang.previousTitle}" onclick="return hs.previous(this)">' +
                                                                                                  '<span>{hs.lang.previousText}</span></a>' +
                                                                                                  '</li>' +
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 112..133

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

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

                                                                                                      hs.loading = hs.createElement('a', {
                                                                                                              className: 'highslide-loading',
                                                                                                              title: hs.lang.loadingTitle,
                                                                                                              innerHTML: hs.lang.loadingText,
                                                                                                              href: 'javascript:;'
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 938..949
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 762..773
                                                                                      assets/images/js/highslide/highslide.js on lines 598..609

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

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

                                                                                              for (var i = 0; i < hs.overrides.length; i++) {
                                                                                                  var name = hs.overrides[i];
                                                                                                  this[name] = params && typeof params[name] != 'undefined' ?
                                                                                                      params[name] : hs[name];
                                                                                              }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1381..1385
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1186..1190
                                                                                      assets/images/js/highslide/highslide.js on lines 999..1003

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

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

                                                                                                  var after = up ?
                                                                                                      function () {
                                                                                      
                                                                                                          if (exp.outline) exp.outline.table.style.visibility = "visible";
                                                                                                          setTimeout(function () {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2048..2058
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1578..1588
                                                                                      assets/images/js/highslide/highslide.js on lines 1330..1340

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

                                                                                      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 (up) {
                                                                                                      this.wrapper.style.visibility = 'visible';
                                                                                                      this.content.style.visibility = 'visible';
                                                                                                      if (this.isHtml) this.innerContent.style.visibility = 'visible';
                                                                                                      this.a.className += ' highslide-active-anchor';
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2096..2101

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

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

                                                                                          if (hs.ie && window == window.top) {
                                                                                              (function () {
                                                                                                  try {
                                                                                                      document.documentElement.doScroll('left');
                                                                                                  } catch (e) {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 3339..3349
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 2633..2643
                                                                                      assets/images/js/highslide/highslide.js on lines 1870..1880

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

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

                                                                                              removeEventListener: function (el, event, func) {
                                                                                                  try {
                                                                                                      el.removeEventListener(event, func, false);
                                                                                                  } catch (e) {
                                                                                                      try {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 868..878
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 693..703
                                                                                      assets/images/js/highslide/highslide.js on lines 529..539

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

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

                                                                                              setPos: function (i) {
                                                                                                  this.pos = i;
                                                                                                  this.exp.wrapper.style[this.lt] = i + 'px';
                                                                                      
                                                                                                  if (this.exp.outline) this.exp.outline.setPosition();
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1352..1358
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1158..1164
                                                                                      assets/images/js/highslide/highslide.js on lines 973..979

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

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

                                                                                                          if (this.isImage && this.x.full > (this.x.imgSize || this.x.size)) {
                                                                                                              this.createFullExpand();
                                                                                                              if (this.overlays.length == 1) this.sizeOverlayBox();
                                                                                                          }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1671..1674
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1391..1394
                                                                                      assets/images/js/highslide/highslide.js on lines 1175..1178

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

                                                                                      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 4 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/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2346..2350
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1844..1848
                                                                                      assets/images/js/highslide/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 4 locations. Consider refactoring.
                                                                                      Open

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

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

                                                                                              calcBorders: function () {
                                                                                                  // correct for borders
                                                                                                  this.cb = (this.exp.content['offset' + this.ucwh] - this.t) / 2;
                                                                                      
                                                                                                  this.marginMax = hs['margin' + this.ucrb];
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1275..1280
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1095..1100
                                                                                      assets/images/js/highslide/highslide.js on lines 920..925

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

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

                                                                                              resizeTo: function (w, h) {
                                                                                                  this.y.setSize(h);
                                                                                                  this.x.setSize(w);
                                                                                                  this.wrapper.style.height = this.y.get('wsize') + 'px';
                                                                                              },
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2581..2585
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 2071..2075
                                                                                      assets/images/js/highslide/highslide.js on lines 1575..1579

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

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                                  if (this.dim == 'y' && exp.iDoc && exp.body.style.height != 'auto') try {
                                                                                                      exp.iDoc.body.style.overflow = 'auto';
                                                                                                  } catch (e) {
                                                                                                  }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1333..1336

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

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

                                                                                              reOrder: function () {
                                                                                                  for (var i = 0; i < hs.expanders.length; i++)
                                                                                                      if (hs.expanders[i] && hs.expanders[i].isExpanded) hs.focusTopmost();
                                                                                              },
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 709..712
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 565..568
                                                                                      assets/images/js/highslide/highslide.js on lines 401..404

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

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

                                                                                          hs.fx = function (elem, options, prop) {
                                                                                              this.options = options;
                                                                                              this.elem = elem;
                                                                                              this.prop = prop;
                                                                                      
                                                                                      
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 2 hrs to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1017..1023
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 837..843
                                                                                      assets/images/js/highslide/highslide.js on lines 664..670

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

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

                                                                                              this.wrapper = hs.createElement(
                                                                                                  'div', {
                                                                                                      id: 'highslide-wrapper-' + this.key,
                                                                                                      className: 'highslide-wrapper ' + this.wrapperClassName
                                                                                                  }, {
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1425..1433
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1228..1236
                                                                                      assets/images/js/highslide/highslide.js on lines 1040..1048

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

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

                                                                                              doShowHide: function (visibility) {
                                                                                                  if (hs.hideSelects) this.showHideElements('SELECT', visibility);
                                                                                                  if (hs.hideIframes) this.showHideElements('IFRAME', visibility);
                                                                                                  if (hs.geckoMac) this.showHideElements('*', visibility);
                                                                                              },
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2483..2487
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1978..1982
                                                                                      assets/images/js/highslide/highslide.js on lines 1483..1487

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

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                                  if (this.isHtml && this.preserveContent) {
                                                                                                      this.overlayBox.style.top = '-9999px';
                                                                                                      hs.container.appendChild(this.overlayBox);
                                                                                                  } else
                                                                                                      hs.discardElement(this.overlayBox);
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2919..2923

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

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

                                                                                              ready: function () {
                                                                                                  if (hs.isReady) return;
                                                                                                  hs.isReady = true;
                                                                                                  for (var i = 0; i < hs.onReady.length; i++) hs.onReady[i]();
                                                                                              },
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 977..981
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 798..802
                                                                                      assets/images/js/highslide/highslide.js on lines 625..629

                                                                                      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

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

                                                                                              cancelLoading: function () {
                                                                                                  hs.discardElement(this.wrapper);
                                                                                                  hs.expanders[this.key] = null;
                                                                                                  if (this.loading) hs.loading.style.left = '-9999px';
                                                                                              },
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1421..1425

                                                                                      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

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

                                                                                                  if (this.maincontent) {
                                                                                                      var body = hs.getElementByClass(this.content, 'div', 'highslide-body');
                                                                                                      if (body) body.appendChild(this.maincontent);
                                                                                                      this.maincontent.style.display = 'block';
                                                                                                  }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1537..1541

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

                                                                                      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

                                                                                              getAdjacentAnchor: function (op) {
                                                                                                  var current = this.getAnchorIndex(), as = hs.anchors.groups[this.slideshowGroup || 'none'];
                                                                                                  return (as && as[current + op]) || null;
                                                                                              },
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide.js on lines 1407..1410

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

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

                                                                                                      hs.container = hs.createElement('div', {
                                                                                                              className: 'highslide-container'
                                                                                                          }, {
                                                                                                              position: 'absolute',
                                                                                                              left: 0,
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 925..937
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 749..761
                                                                                      assets/images/js/highslide/highslide.js on lines 585..597

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

                                                                                      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 (this.outline && !this.outlineWhileAnimating) {
                                                                                                      if (up) this.outline.setPosition();
                                                                                                      else this.outline.destroy(
                                                                                                          (this.isHtml && this.preserveContent));
                                                                                                  }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2034..2038

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

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

                                                                                              error: function (e) {
                                                                                                  if (hs.debug) alert('Line ' + e.lineNumber + ': ' + e.message);
                                                                                                  else window.location.href = this.src;
                                                                                              },
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1462..1465
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1265..1268
                                                                                      assets/images/js/highslide/highslide.js on lines 1076..1079

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

                                                                                      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 (!hs.allowMultipleInstances && hs.focusKey != this.key) {
                                                                                                          try {
                                                                                                              hs.expanders[hs.focusKey].close();
                                                                                                          } catch (e) {
                                                                                                          }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2665..2670

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

                                                                                      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 (blurExp.isImage) {
                                                                                                              blurExp.content.style.cursor = hs.ieLt7 ? 'hand' : 'pointer';
                                                                                                              blurExp.content.title = hs.lang.focusTitle;
                                                                                                          }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2541..2544

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

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

                                                                                              if (document.readyState && hs.ie && !hs.isReady) {
                                                                                                  hs.addEventListener(document, 'ready', function () {
                                                                                                      new hs.Expander(a, params, custom, contentType);
                                                                                                  });
                                                                                                  return;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1362..1367
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1168..1173
                                                                                      assets/images/js/highslide/highslide.js on lines 983..988

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

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

                                                                                                  if (this.fadeInOut) {
                                                                                                      hs.setStyles(this.wrapper, {opacity: up ? 0 : 1});
                                                                                                      hs.extend(to.wrapper, {opacity: up});
                                                                                                  }
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2069..2072
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1593..1596
                                                                                      assets/images/js/highslide/highslide.js on lines 1345..1348

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

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

                                                                                                      hs.hideIframes = ((window.opera && hs.uaVersion < 9) || navigator.vendor == 'KDE'
                                                                                                      || (hs.ieLt7 && hs.uaVersion < 5.5));
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 972..973
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 794..795
                                                                                      assets/images/js/highslide/highslide.js on lines 621..622

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

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

                                                                                              uaVersion: /Trident\/4\.0/.test(navigator.userAgent) ? 8 :
                                                                                                  parseFloat((navigator.userAgent.toLowerCase().match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/) || [0, '0'])[1]),
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 hr to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 215..216
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 169..170
                                                                                      assets/images/js/highslide/highslide.js on lines 104..105

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

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

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

                                                                                      Duplicated Code

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

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

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

                                                                                      Tuning

                                                                                      This issue has a mass of 55.

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                          hs.Ajax = function (a, content, pre) {
                                                                                              this.a = a;
                                                                                              this.content = content;
                                                                                              this.pre = pre;
                                                                                          };
                                                                                      Severity: Minor
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 55 mins to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 3001..3005

                                                                                      Duplicated Code

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

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

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

                                                                                      Tuning

                                                                                      This issue has a mass of 54.

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                                  var p = hs.page, mX = hs.mouse.x + p.scrollLeft, mY = hs.mouse.y + p.scrollTop;
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 55 mins to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2324..2324
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1823..1823
                                                                                      assets/images/js/highslide/highslide.js on lines 1379..1379

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

                                                                                      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

                                                                                                  this.content = hs.createElement(
                                                                                                      'div', {
                                                                                                          className: 'highslide-html'
                                                                                                      }, {
                                                                                                          position: 'relative',
                                                                                      Severity: Minor
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 55 mins to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1554..1564

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

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

                                                                                              registerOverlay: function (overlay) {
                                                                                                  hs.push(hs.overlays, hs.extend(overlay, {hsId: 'hsId' + hs.idCounter++}));
                                                                                              },
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 50 mins to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 654..656
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 510..512
                                                                                      assets/images/js/highslide/highslide.js on lines 361..363

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

                                                                                      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

                                                                                                  hs.setStyles(this.wrapper, {
                                                                                                      position: 'static',
                                                                                                      padding: '0 ' + hs.marginRight + 'px 0 ' + hs.marginLeft + 'px'
                                                                                                  });
                                                                                      Severity: Minor
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 50 mins to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 1550..1553

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

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

                                                                                              isHsAnchor: function (a) {
                                                                                                  return (a.onclick && a.onclick.toString().replace(/\s/g, ' ').match(/hs.(htmlE|e)xpand/));
                                                                                              },
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 45 mins to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 705..707
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 561..563
                                                                                      assets/images/js/highslide/highslide.js on lines 397..399

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

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

                                                                                          hs.addEventListener(document, 'mousemove', function (e) {
                                                                                              hs.mouse = {x: e.clientX, y: e.clientY};
                                                                                          });
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 40 mins to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 3396..3398
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 2690..2692
                                                                                      assets/images/js/highslide/highslide.js on lines 1913..1915

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

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

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

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

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

                                                                                      Refactorings

                                                                                      Further Reading

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

                                                                                                  if (this.isHtml && this.preserveContent) {
                                                                                                      this.sleep();
                                                                                                  } else {
                                                                                                      if (this.outline && this.outlineWhileAnimating) this.outline.destroy();
                                                                                      
                                                                                      
                                                                                      Severity: Minor
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 40 mins to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2979..2986

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

                                                                                      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

                                                                                              getSelfRendered: function () {
                                                                                                  return hs.createElement('div', {
                                                                                                      className: 'highslide-html-content',
                                                                                                      innerHTML: hs.replaceLang(hs.skin.contentWrapper)
                                                                                                  });
                                                                                      Severity: Minor
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 1 other location - About 40 mins to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 364..369

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

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

                                                                                                  if (up) hs.setStyles(this.wrapper, {
                                                                                                      width: x.t + 'px',
                                                                                                      height: y.t + 'px'
                                                                                                  });
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 35 mins to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 2059..2062
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 1589..1592
                                                                                      assets/images/js/highslide/highslide.js on lines 1341..1344

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

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

                                                                                              discardElement: function (d) {
                                                                                                  if (d) hs.garbageBin.appendChild(d);
                                                                                                  hs.garbageBin.innerHTML = '';
                                                                                              },
                                                                                      Severity: Major
                                                                                      Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 30 mins to fix
                                                                                      assets/images/js/highslide/highslide-full.js on lines 505..508
                                                                                      assets/images/js/highslide/highslide-with-gallery.js on lines 363..366
                                                                                      assets/images/js/highslide/highslide.js on lines 278..281

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

                                                                                      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