Jupiterrr/Vorlesungsverzeichnis

View on GitHub
app/assets/components/bootstrap-css/js/bootstrap.js

Summary

Maintainability
F
2 wks
Test Coverage

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

/* ===================================================
 * bootstrap-transition.js v2.3.1
 * http://twitter.github.com/bootstrap/javascript.html#transitions
 * ===================================================
 * Copyright 2012 Twitter, Inc.
Severity: Major
Found in app/assets/components/bootstrap-css/js/bootstrap.js - About 4 days to fix

    Function slide has 45 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

      , slide: function (type, next) {
          var $active = this.$element.find('.item.active')
            , $next = next || $active[type]()
            , isCycling = this.interval
            , direction = type == 'next' ? 'left' : 'right'
    Severity: Minor
    Found in app/assets/components/bootstrap-css/js/bootstrap.js - About 1 hr to fix

      Function show has 42 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

        , show: function () {
            var $tip
              , pos
              , actualWidth
              , actualHeight
      Severity: Minor
      Found in app/assets/components/bootstrap-css/js/bootstrap.js - About 1 hr to fix

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

          , applyPlacement: function(offset, placement){
              var $tip = this.tip()
                , width = $tip[0].offsetWidth
                , height = $tip[0].offsetHeight
                , actualWidth
        Severity: Minor
        Found in app/assets/components/bootstrap-css/js/bootstrap.js - About 1 hr to fix

          Function keydown has 26 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

            , keydown: function (e) {
                var $this
                  , $items
                  , $active
                  , $parent
          Severity: Minor
          Found in app/assets/components/bootstrap-css/js/bootstrap.js - About 1 hr to fix

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

                    switch (placement) {
                      case 'bottom':
                        tp = {top: pos.top + pos.height, left: pos.left + pos.width / 2 - actualWidth / 2}
                        break
                      case 'top':
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 1 day to fix
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 131..144

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

            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

              , leave: function (e) {
                  var self = $(e.currentTarget)[this.type](this._options).data(this.type)
            
                  if (this.timeout) clearTimeout(this.timeout)
                  if (!self.options.delay || !self.options.delay.hide) return self.hide()
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 7 hrs to fix
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 86..96

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

            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

              $.fn.tooltip = function ( option ) {
                return this.each(function () {
                  var $this = $(this)
                    , data = $this.data('tooltip')
                    , options = typeof option == 'object' && option
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 6 other locations - About 4 hrs to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1492..1500
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1646..1654
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2120..2128
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2232..2240
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 253..261
            app/assets/javascripts/twitter/bootstrap-typeahead.js on lines 277..285

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

              $.fn.popover = function (option) {
                return this.each(function () {
                  var $this = $(this)
                    , data = $this.data('popover')
                    , options = typeof option == 'object' && option
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 6 other locations - About 4 hrs to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1373..1381
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1646..1654
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2120..2128
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2232..2240
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 253..261
            app/assets/javascripts/twitter/bootstrap-typeahead.js on lines 277..285

            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 7 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 app/assets/components/bootstrap-css/js/bootstrap.js and 6 other locations - About 4 hrs to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1373..1381
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1492..1500
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1646..1654
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2232..2240
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 253..261
            app/assets/javascripts/twitter/bootstrap-typeahead.js on lines 277..285

            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 7 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 app/assets/components/bootstrap-css/js/bootstrap.js and 6 other locations - About 4 hrs to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1373..1381
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1492..1500
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2120..2128
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2232..2240
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 253..261
            app/assets/javascripts/twitter/bootstrap-typeahead.js on lines 277..285

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

              $.fn.affix = function (option) {
                return this.each(function () {
                  var $this = $(this)
                    , data = $this.data('affix')
                    , options = typeof option == 'object' && option
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 6 other locations - About 4 hrs to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1373..1381
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1492..1500
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1646..1654
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2120..2128
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 253..261
            app/assets/javascripts/twitter/bootstrap-typeahead.js on lines 277..285

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

              $.fn.dropdown = function (option) {
                return this.each(function () {
                  var $this = $(this)
                    , data = $this.data('dropdown')
                  if (!data) $this.data('dropdown', (data = new Dropdown(this)))
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 2 other locations - About 3 hrs to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 132..139
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 129..136

            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

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

              $.fn.alert = function (option) {
                return this.each(function () {
                  var $this = $(this)
                    , data = $this.data('alert')
                  if (!data) $this.data('alert', (data = new Alert(this)))
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 2 other locations - About 3 hrs to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 767..774
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 129..136

            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

              , toggle: function (e) {
                  var $this = $(this)
                    , $parent
                    , isActive
            
            
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 3 hrs to fix
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 40..60

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

            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

              , next: function (event) {
                  var active = this.$menu.find('.active').removeClass('active')
                    , next = active.next()
            
                  if (!next.length) {
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 3 hrs to fix
            app/assets/javascripts/twitter/bootstrap-typeahead.js on lines 168..177

            Duplicated Code

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

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

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

            Tuning

            This issue has a mass of 101.

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

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

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

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

            Refactorings

            Further Reading

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

                  function removeWithAnimation() {
                    var timeout = setTimeout(function () {
                      $tip.off($.support.transition.end).detach()
                    }, 500)
            
            
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 3 hrs to fix
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 167..176

            Duplicated Code

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

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

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

            Tuning

            This issue has a mass of 101.

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

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

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

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

            Refactorings

            Further Reading

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

              , prev: function (event) {
                  var active = this.$menu.find('.active').removeClass('active')
                    , prev = active.prev()
            
                  if (!prev.length) {
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 3 hrs to fix
            app/assets/javascripts/twitter/bootstrap-typeahead.js on lines 179..188

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

            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

                  switch(e.keyCode) {
                    case 9: // tab
                    case 13: // enter
                    case 27: // escape
                      e.preventDefault()
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 3 hrs to fix
            app/assets/javascripts/twitter/bootstrap-typeahead.js on lines 234..250

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

            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

              , getTitle: function () {
                  var title
                    , $e = this.$element
                    , o = this.options
            
            
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 2 hrs to fix
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 203..212

            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 (!item.toLowerCase().indexOf(this.query.toLowerCase())) beginswith.push(item)
                    else if (~item.indexOf(this.query)) caseSensitive.push(item)
                    else caseInsensitive.push(item)
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 2 hrs to fix
            app/assets/javascripts/twitter/bootstrap-typeahead.js on lines 138..140

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

              var toggle = '[data-toggle=dropdown]'
                , Dropdown = function (element) {
                    var $el = $(element).on('click.dropdown.data-api', this.toggle)
                    $('html').on('click.dropdown.data-api', function () {
                      $el.parent().removeClass('open')
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 2 hrs to fix
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 28..34

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

            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

              , setContent: function () {
                  var $tip = this.tip()
                    , title = this.getTitle()
            
                  $tip.find('.tooltip-inner')[this.options.html ? 'html' : 'text'](title)
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 2 hrs to fix
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 153..159

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

            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

              , eventSupported: function(eventName) {
                  var isSupported = eventName in this.$element
                  if (!isSupported) {
                    this.$element.setAttribute(eventName, 'return;')
                    isSupported = typeof this.$element[eventName] === 'function'
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 2 hrs to fix
            app/assets/components/bootstrap-markdown/js/bootstrap-markdown.js on lines 509..516

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

            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

                  var $this = $(this)
                    , data = $this.data('collapse')
                    , options = $.extend({}, $.fn.collapse.defaults, $this.data(), typeof option == 'object' && option)
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 1 hr to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1000..1002

            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

                  var $this = $(this)
                    , data = $this.data('modal')
                    , options = $.extend({}, $.fn.modal.defaults, $this.data(), typeof option == 'object' && option)
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 1 hr to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 597..599

            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

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

                    placement = typeof this.options.placement == 'function' ?
                      this.options.placement.call(this, $tip[0], this.$element[0]) :
                      this.options.placement
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 1 hr to fix
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 115..117

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

              , validate: function () {
                  if (!this.$element[0].parentNode) {
                    this.hide()
                    this.$element = null
                    this.options = null
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 2 other locations - About 1 hr to fix
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 218..224
            app/assets/javascripts/twitter/bootstrap-twipsy.js on lines 174..180

            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

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

                      $.support.transition && this.$element.hasClass('fade')?
                        this.$backdrop.one($.support.transition.end, callback) :
                        callback()
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 1 hr to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 578..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 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 2 locations. Consider refactoring.
            Open

                  $.support.transition && this.$element.hasClass('collapse') ?
                    this.$element.one($.support.transition.end, complete) :
                    complete()
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 1 hr to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 982..984

            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

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

                if (!selector) {
                  selector = $this.attr('href')
                  selector = selector && /#/.test(selector) && selector.replace(/.*(?=#[^\s]*$)/, '') //strip for ie7
                }
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 1 hr to fix
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 112..115

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

            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

                  this.options.selector ?
                    (this._options = $.extend({}, this.options, { trigger: 'manual', selector: '' })) :
                    this.fixTitle()
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 1 hr to fix
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 56..58

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

            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 (options.delay && typeof options.delay == 'number') {
                    options.delay = {
                      show: options.delay
                    , hide: options.delay
                    }
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 1 hr to fix
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 64..69

            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

              , destroy: function () {
                  this.hide().$element.off('.' + this.type).removeData(this.type)
                }
            Severity: Minor
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 55 mins to fix
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 243..245

            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

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

              , keydown: function (e) {
                  this.suppressKeyPressRepeat = ~$.inArray(e.keyCode, [40,38,9,13,27])
                  this.move(e)
                }
            Severity: Minor
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 55 mins to fix
            app/assets/components/bootstrap-markdown/js/bootstrap-markdown.js on lines 518..521

            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

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

                      this.$element.on(eventOut + '.' + this.type, this.options.selector, $.proxy(this.leave, this))
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 3 other locations - About 45 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1104..1104
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 52..52
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 53..53

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

                  this.$menu
                    .on('click', $.proxy(this.click, this))
                    .on('mouseenter', 'li', $.proxy(this.mouseenter, this))
            Severity: Minor
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 45 mins to fix
            app/assets/javascripts/twitter/bootstrap-typeahead.js on lines 200..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 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

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

                      this.$element.on(eventIn + '.' + this.type, this.options.selector, $.proxy(this.enter, this))
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 3 other locations - About 45 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1105..1105
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 52..52
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 53..53

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

                    if (trigger == 'click') {
                      this.$element.on('click.' + this.type, this.options.selector, $.proxy(this.toggle, this))
                    } else if (trigger != 'manual') {
                      eventIn = trigger == 'hover' ? 'mouseenter' : 'focus'
                      eventOut = trigger == 'hover' ? 'mouseleave' : 'blur'
            Severity: Minor
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 45 mins to fix
            app/assets/javascripts/twitter/bootstrap-tooltip.js on lines 47..54

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

              function clearMenus() {
                $(toggle).each(function () {
                  getParent($(this)).removeClass('open')
                })
              }
            Severity: Minor
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 35 mins to fix
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 102..106

            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

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

              , mouseleave: function (e) {
                  this.mousedover = false
                  if (!this.focused && this.shown) this.hide()
                }
            Severity: Minor
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2089..2092

            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

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

              , blur: function (e) {
                  this.focused = false
                  if (!this.mousedover && this.shown) this.hide()
                }
            Severity: Minor
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2107..2110

            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

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

                  var pos = $.extend({}, this.$element.position(), {
                    height: this.$element[0].offsetHeight
                  })
            Severity: Minor
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 35 mins to fix
            app/assets/javascripts/twitter/bootstrap-typeahead.js on lines 58..60

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

                if (!selector) {
                  selector = $this.attr('href')
                  selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') //strip for ie7
                }
            Severity: Minor
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1726..1729

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

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

              $.fn.collapse.noConflict = function () {
                $.fn.collapse = old
                return this
              }
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 9 other locations - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 147..150
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 247..250
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 445..448
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 782..785
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1021..1024
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1811..1814
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2144..2147
            app/assets/components/bootstrap-markdown/js/bootstrap-markdown.js on lines 913..916
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 144..147

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

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

              $.fn.typeahead.noConflict = function () {
                $.fn.typeahead = old
                return this
              }
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 9 other locations - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 147..150
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 247..250
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 445..448
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 615..618
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 782..785
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1021..1024
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1811..1814
            app/assets/components/bootstrap-markdown/js/bootstrap-markdown.js on lines 913..916
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 144..147

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

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

              $.fn.alert.noConflict = function () {
                $.fn.alert = old
                return this
              }
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 9 other locations - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 247..250
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 445..448
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 615..618
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 782..785
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1021..1024
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1811..1814
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2144..2147
            app/assets/components/bootstrap-markdown/js/bootstrap-markdown.js on lines 913..916
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 144..147

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

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

              $.fn.dropdown.noConflict = function () {
                $.fn.dropdown = old
                return this
              }
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 9 other locations - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 147..150
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 247..250
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 445..448
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 615..618
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1021..1024
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1811..1814
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2144..2147
            app/assets/components/bootstrap-markdown/js/bootstrap-markdown.js on lines 913..916
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 144..147

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

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

              $.fn.button.noConflict = function () {
                $.fn.button = old
                return this
              }
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 9 other locations - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 147..150
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 445..448
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 615..618
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 782..785
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1021..1024
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1811..1814
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2144..2147
            app/assets/components/bootstrap-markdown/js/bootstrap-markdown.js on lines 913..916
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 144..147

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

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

              $.fn.tab.noConflict = function () {
                $.fn.tab = old
                return this
              }
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 9 other locations - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 147..150
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 247..250
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 445..448
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 615..618
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 782..785
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1021..1024
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2144..2147
            app/assets/components/bootstrap-markdown/js/bootstrap-markdown.js on lines 913..916
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 144..147

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

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

              $.fn.carousel.noConflict = function () {
                $.fn.carousel = old
                return this
              }
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 9 other locations - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 147..150
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 247..250
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 615..618
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 782..785
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1021..1024
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1811..1814
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2144..2147
            app/assets/components/bootstrap-markdown/js/bootstrap-markdown.js on lines 913..916
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 144..147

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

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

              $.fn.modal.noConflict = function () {
                $.fn.modal = old
                return this
              }
            Severity: Major
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 9 other locations - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 147..150
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 247..250
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 445..448
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 615..618
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 782..785
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 1811..1814
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 2144..2147
            app/assets/components/bootstrap-markdown/js/bootstrap-markdown.js on lines 913..916
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 144..147

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

            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 (!selector) {
                    selector = $this.attr('href')
                    selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') //strip for ie7
                  }
            Severity: Minor
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 35 mins to fix
            app/assets/components/bootstrap-css/js/bootstrap.js on lines 98..101

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

            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

              $(document)
                .on('click.dropdown.data-api', clearMenus)
                .on('click.dropdown.data-api', '.dropdown form', function (e) { e.stopPropagation() })
                .on('click.dropdown-menu', function (e) { e.stopPropagation() })
            Severity: Minor
            Found in app/assets/components/bootstrap-css/js/bootstrap.js and 1 other location - About 30 mins to fix
            app/assets/javascripts/twitter/bootstrap-dropdown.js on lines 153..156

            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