savonarola/pulse_meter_visualizer

View on GitHub

Showing 114 of 114 total issues

File jquery-ui-timepicker-addon.js has 1294 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/*
* jQuery timepicker addon
* By: Trent Richardson [http://trentrichardson.com]
* Version 1.0.2
* Last Modified: 07/01/2012
Severity: Major
Found in lib/pulse_meter/visualize/public/js/jquery-ui-timepicker-addon.js - About 3 days to fix

    File bootstrap.js has 1120 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    /* ===================================================
     * bootstrap-transition.js v2.0.3
     * http://twitter.github.com/bootstrap/javascript.html#transitions
     * ===================================================
     * Copyright 2012 Twitter, Inc.
    Severity: Major
    Found in lib/pulse_meter/visualize/public/js/bootstrap.js - About 2 days to fix

      File application.js has 890 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      
      String.prototype.capitalize = function() {
        return this.charAt(0).toUpperCase() + this.slice(1);
      };
      
      
      Severity: Major
      Found in lib/pulse_meter/visualize/public/js/application.js - About 2 days to fix

        Function _injectTimePicker has 285 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            _injectTimePicker: function() {
                var $dp = this.inst.dpDiv,
                    o = this.inst.settings,
                    tp_inst = this,
                    // Added by Peter Medeiros:
        Severity: Major
        Found in lib/pulse_meter/visualize/public/js/jquery-ui-timepicker-addon.js - About 1 day to fix

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

                      if (o.showMillisec && o.millisecGrid > 0) {
                          $tp.find(".ui_tpicker_millisec table").css({
                              width: size + "%",
                              marginLeft: (size / (-2 * millisecGridSize)) + "%",
                              borderCollapse: 'collapse'
          lib/pulse_meter/visualize/public/js/jquery-ui-timepicker-addon.js on lines 544..561

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

          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 (o.showSecond && o.secondGrid > 0) {
                          $tp.find(".ui_tpicker_second table").css({
                              width: size + "%",
                              marginLeft: (size / (-2 * secondGridSize)) + "%",
                              borderCollapse: 'collapse'
          lib/pulse_meter/visualize/public/js/jquery-ui-timepicker-addon.js on lines 563..580

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

          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

            , enter: function (e) {
                var self = $(e.currentTarget)[this.type](this._options).data(this.type)
          
                if (!self.options.delay || !self.options.delay.show) return self.show()
          
          
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/bootstrap.js and 1 other location - About 6 hrs to fix
          lib/pulse_meter/visualize/public/js/bootstrap.js on lines 749..759

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

          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

            , leave: function (e) {
                var self = $(e.currentTarget)[this.type](this._options).data(this.type)
          
                if (!self.options.delay || !self.options.delay.hide) return self.hide()
          
          
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/bootstrap.js and 1 other location - About 6 hrs to fix
          lib/pulse_meter/visualize/public/js/bootstrap.js on lines 737..747

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

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

          var AreaPresenter,
            __hasProp = {}.hasOwnProperty,
            __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/application.js and 6 other locations - About 4 hrs to fix
          lib/pulse_meter/visualize/public/js/application.js on lines 311..313
          lib/pulse_meter/visualize/public/js/application.js on lines 348..350
          lib/pulse_meter/visualize/public/js/application.js on lines 383..385
          lib/pulse_meter/visualize/public/js/application.js on lines 450..452
          lib/pulse_meter/visualize/public/js/application.js on lines 484..486
          lib/pulse_meter/visualize/public/js/application.js on lines 510..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 134.

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

          var GaugePresenter,
            __hasProp = {}.hasOwnProperty,
            __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/application.js and 6 other locations - About 4 hrs to fix
          lib/pulse_meter/visualize/public/js/application.js on lines 311..313
          lib/pulse_meter/visualize/public/js/application.js on lines 348..350
          lib/pulse_meter/visualize/public/js/application.js on lines 383..385
          lib/pulse_meter/visualize/public/js/application.js on lines 450..452
          lib/pulse_meter/visualize/public/js/application.js on lines 467..469
          lib/pulse_meter/visualize/public/js/application.js on lines 484..486

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

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

          var LinePresenter,
            __hasProp = {}.hasOwnProperty,
            __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/application.js and 6 other locations - About 4 hrs to fix
          lib/pulse_meter/visualize/public/js/application.js on lines 311..313
          lib/pulse_meter/visualize/public/js/application.js on lines 348..350
          lib/pulse_meter/visualize/public/js/application.js on lines 383..385
          lib/pulse_meter/visualize/public/js/application.js on lines 467..469
          lib/pulse_meter/visualize/public/js/application.js on lines 484..486
          lib/pulse_meter/visualize/public/js/application.js on lines 510..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 134.

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

          var PiePresenter,
            __hasProp = {}.hasOwnProperty,
            __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/application.js and 6 other locations - About 4 hrs to fix
          lib/pulse_meter/visualize/public/js/application.js on lines 348..350
          lib/pulse_meter/visualize/public/js/application.js on lines 383..385
          lib/pulse_meter/visualize/public/js/application.js on lines 450..452
          lib/pulse_meter/visualize/public/js/application.js on lines 467..469
          lib/pulse_meter/visualize/public/js/application.js on lines 484..486
          lib/pulse_meter/visualize/public/js/application.js on lines 510..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 134.

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

          var TimelinePresenter,
            __hasProp = {}.hasOwnProperty,
            __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/application.js and 6 other locations - About 4 hrs to fix
          lib/pulse_meter/visualize/public/js/application.js on lines 311..313
          lib/pulse_meter/visualize/public/js/application.js on lines 383..385
          lib/pulse_meter/visualize/public/js/application.js on lines 450..452
          lib/pulse_meter/visualize/public/js/application.js on lines 467..469
          lib/pulse_meter/visualize/public/js/application.js on lines 484..486
          lib/pulse_meter/visualize/public/js/application.js on lines 510..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 134.

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

          var SeriesPresenter,
            __hasProp = {}.hasOwnProperty,
            __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/application.js and 6 other locations - About 4 hrs to fix
          lib/pulse_meter/visualize/public/js/application.js on lines 311..313
          lib/pulse_meter/visualize/public/js/application.js on lines 348..350
          lib/pulse_meter/visualize/public/js/application.js on lines 450..452
          lib/pulse_meter/visualize/public/js/application.js on lines 467..469
          lib/pulse_meter/visualize/public/js/application.js on lines 484..486
          lib/pulse_meter/visualize/public/js/application.js on lines 510..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 134.

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

          var TablePresenter,
            __hasProp = {}.hasOwnProperty,
            __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/application.js and 6 other locations - About 4 hrs to fix
          lib/pulse_meter/visualize/public/js/application.js on lines 311..313
          lib/pulse_meter/visualize/public/js/application.js on lines 348..350
          lib/pulse_meter/visualize/public/js/application.js on lines 383..385
          lib/pulse_meter/visualize/public/js/application.js on lines 450..452
          lib/pulse_meter/visualize/public/js/application.js on lines 467..469
          lib/pulse_meter/visualize/public/js/application.js on lines 510..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 134.

          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.second <= this._defaults.secondMin){
                                      this.second = this._defaults.secondMin;
                                      this._defaults.millisecMin = minDateTime.getMilliseconds();
                                  }
                                  else {
          lib/pulse_meter/visualize/public/js/jquery-ui-timepicker-addon.js on lines 709..715

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

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

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

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

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

          Refactorings

          Further Reading

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

                              } else if (this.second >= this._defaults.secondMax) {
                                  this.second = this._defaults.secondMax;
                                  this._defaults.millisecMax = maxDateTime.getMilliseconds();
                              } else {
                                  if(this.millisec > this._defaults.millisecMax) { this.millisec = this._defaults.millisecMax; }
          lib/pulse_meter/visualize/public/js/jquery-ui-timepicker-addon.js on lines 660..669

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

          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

            $.fn.tooltip = function ( option ) {
              return this.each(function () {
                var $this = $(this)
                  , data = $this.data('tooltip')
                  , options = typeof option == 'object' && option
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/bootstrap.js and 3 other locations - About 4 hrs to fix
          lib/pulse_meter/visualize/public/js/bootstrap.js on lines 503..511
          lib/pulse_meter/visualize/public/js/bootstrap.js on lines 1350..1358
          lib/pulse_meter/visualize/public/js/bootstrap.js on lines 1803..1811

          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

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

            $.fn.typeahead = function (option) {
              return this.each(function () {
                var $this = $(this)
                  , data = $this.data('typeahead')
                  , options = typeof option == 'object' && option
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/bootstrap.js and 3 other locations - About 4 hrs to fix
          lib/pulse_meter/visualize/public/js/bootstrap.js on lines 503..511
          lib/pulse_meter/visualize/public/js/bootstrap.js on lines 918..926
          lib/pulse_meter/visualize/public/js/bootstrap.js on lines 1350..1358

          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

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

            $.fn.scrollspy = function ( option ) {
              return this.each(function () {
                var $this = $(this)
                  , data = $this.data('scrollspy')
                  , options = typeof option == 'object' && option
          Severity: Major
          Found in lib/pulse_meter/visualize/public/js/bootstrap.js and 3 other locations - About 4 hrs to fix
          lib/pulse_meter/visualize/public/js/bootstrap.js on lines 918..926
          lib/pulse_meter/visualize/public/js/bootstrap.js on lines 1350..1358
          lib/pulse_meter/visualize/public/js/bootstrap.js on lines 1803..1811

          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

          Severity
          Category
          Status
          Source
          Language