coopdevs/katuma

View on GitHub

Showing 319 of 319 total issues

File jquery-2.1.3.js has 6164 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/*!
 * jQuery JavaScript Library v2.1.3
 * http://jquery.com/
 *
 * Includes Sizzle.js
Severity: Major
Found in vendor/assets/javascripts/jquery-2.1.3.js - About 2 wks to fix

    Function Sizzle has 1355 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    (function( window ) {
    
    var i,
        support,
        Expr,
    Severity: Major
    Found in vendor/assets/javascripts/jquery-2.1.3.js - About 6 days to fix

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

      /*!
       * Bootstrap v3.3.1 (http://getbootstrap.com)
       * Copyright 2011-2014 Twitter, Inc.
       * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
       */
      Severity: Major
      Found in vendor/assets/javascripts/bootstrap.js - About 4 days to fix

        Function ajax has 240 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            ajax: function( url, options ) {
        
                // If url is an object, simulate pre-1.5 signature
                if ( typeof url === "object" ) {
                    options = url;
        Severity: Major
        Found in vendor/assets/javascripts/jquery-2.1.3.js - About 1 day to fix

          Function setDocument has 218 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          setDocument = Sizzle.setDocument = function( node ) {
              var hasCompare, parent,
                  doc = node ? node.ownerDocument || node : preferredDoc;
          
              // If no document and documentElement is available, return
          Severity: Major
          Found in vendor/assets/javascripts/jquery-2.1.3.js - About 1 day to fix

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

              function Plugin(option) {
                return this.each(function () {
                  var $this    = $(this)
                  var data     = $this.data('bs.popover')
                  var options  = typeof option == 'object' && option
            Severity: Major
            Found in vendor/assets/javascripts/bootstrap.js and 1 other location - About 1 day to fix
            vendor/assets/javascripts/bootstrap.js on lines 1672..1688

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

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

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

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

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

            Refactorings

            Further Reading

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

              function Plugin(option) {
                return this.each(function () {
                  var $this    = $(this)
                  var data     = $this.data('bs.tooltip')
                  var options  = typeof option == 'object' && option
            Severity: Major
            Found in vendor/assets/javascripts/bootstrap.js and 1 other location - About 1 day to fix
            vendor/assets/javascripts/bootstrap.js on lines 1792..1808

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

            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

            Function Callbacks has 128 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            jQuery.Callbacks = function( options ) {
            
                // Convert options from String-formatted to Object-formatted if needed
                // (we check in cache first)
                options = typeof options === "string" ?
            Severity: Major
            Found in vendor/assets/javascripts/jquery-2.1.3.js - About 5 hrs to fix

              Consider simplifying this complex logical expression.
              Open

                          if ( event.pageX == null && original.clientX != null ) {
                              eventDoc = event.target.ownerDocument || document;
                              doc = eventDoc.documentElement;
                              body = eventDoc.body;
              
              
              Severity: Critical
              Found in vendor/assets/javascripts/jquery-2.1.3.js - About 5 hrs to fix

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

                  function Plugin(option) {
                    return this.each(function () {
                      var $this   = $(this)
                      var data    = $this.data('bs.affix')
                      var options = typeof option == 'object' && option
                Severity: Major
                Found in vendor/assets/javascripts/bootstrap.js and 1 other location - About 4 hrs to fix
                vendor/assets/javascripts/bootstrap.js on lines 1964..1973

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

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

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

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

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

                Refactorings

                Further Reading

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

                  function Plugin(option) {
                    return this.each(function () {
                      var $this   = $(this)
                      var data    = $this.data('bs.scrollspy')
                      var options = typeof option == 'object' && option
                Severity: Major
                Found in vendor/assets/javascripts/bootstrap.js and 1 other location - About 4 hrs to fix
                vendor/assets/javascripts/bootstrap.js on lines 2274..2283

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

                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

                Function defaultPrefilter has 99 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                function defaultPrefilter( elem, props, opts ) {
                    /* jshint validthis: true */
                    var prop, value, toggle, tween, hooks, oldfire, display, checkDisplay,
                        anim = this,
                        orig = {},
                Severity: Major
                Found in vendor/assets/javascripts/jquery-2.1.3.js - About 3 hrs to fix

                  File products_controller_spec.rb has 315 lines of code (exceeds 250 allowed). Consider refactoring.
                  Open

                  require 'rails_helper'
                  require_relative '../../../../../../../spec/support/shared_examples/controllers.rb'
                  require_relative '../../../../../../../spec/support/authentication.rb'
                  
                  module Products

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

                      function Plugin(option) {
                        return this.each(function () {
                          var $this = $(this)
                          var data  = $this.data('bs.alert')
                    
                    
                    Severity: Major
                    Found in vendor/assets/javascripts/bootstrap.js and 1 other location - About 3 hrs to fix
                    vendor/assets/javascripts/bootstrap.js on lines 864..872

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

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

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

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

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

                    Refactorings

                    Further Reading

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

                      function Plugin(option) {
                        return this.each(function () {
                          var $this = $(this)
                          var data  = $this.data('bs.dropdown')
                    
                    
                    Severity: Major
                    Found in vendor/assets/javascripts/bootstrap.js and 1 other location - About 3 hrs to fix
                    vendor/assets/javascripts/bootstrap.js on lines 141..149

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

                    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

                    Function trigger has 85 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        trigger: function( event, data, elem, onlyHandlers ) {
                    
                            var i, cur, tmp, bubbleType, ontype, handle, special,
                                eventPath = [ elem || document ],
                                type = hasOwn.call( event, "type" ) ? event.type : event,
                    Severity: Major
                    Found in vendor/assets/javascripts/jquery-2.1.3.js - About 3 hrs to fix

                      Function Animation has 84 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                      function Animation( elem, properties, options ) {
                          var result,
                              stopped,
                              index = 0,
                              length = animationPrefilters.length,
                      Severity: Major
                      Found in vendor/assets/javascripts/jquery-2.1.3.js - About 3 hrs to fix

                        File producers_controller_spec.rb has 294 lines of code (exceeds 250 allowed). Consider refactoring.
                        Open

                        require 'rails_helper'
                        require_relative '../../../../../../../spec/support/shared_examples/controllers.rb'
                        require_relative '../../../../../../../spec/support/authentication.rb'
                        
                        module BasicResources

                          Function Sizzle has 75 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                          function Sizzle( selector, context, results, seed ) {
                              var match, elem, m, nodeType,
                                  // QSA vars
                                  i, groups, old, nid, newContext, newSelector;
                          
                          
                          Severity: Major
                          Found in vendor/assets/javascripts/jquery-2.1.3.js - About 3 hrs to fix

                            File orders_frequencies_controller_spec.rb has 290 lines of code (exceeds 250 allowed). Consider refactoring.
                            Open

                            require 'rails_helper'
                            require_relative '../../../../../../../spec/support/shared_examples/controllers.rb'
                            require_relative '../../../../../../../spec/support/authentication.rb'
                            
                            module Suppliers
                              Severity
                              Category
                              Status
                              Source
                              Language