azproduction/autopolyfiller

View on GitHub

Showing 135 of 135 total issues

Function addClass has 27 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    addClass: function( value ) {
        var classNames, i, l, elem,
            setClass, c, cl;

        if ( jQuery.isFunction( value ) ) {
Severity: Minor
Found in benchmark/scan/assets/jquery.js - About 1 hr to fix

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

            if ( jQuery.isFunction( html ) ) {
                return this.each(function(i) {
                    jQuery(this).wrapInner( html.call(this, i) );
                });
            }
    Severity: Major
    Found in benchmark/scan/assets/jquery.js and 1 other location - About 1 hr to fix
    benchmark/scan/assets/jquery.js on lines 5501..5505

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

    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 ( jQuery.isFunction( html ) ) {
                return this.each(function(i) {
                    jQuery(this).wrapAll( html.call(this, i) );
                });
            }
    Severity: Major
    Found in benchmark/scan/assets/jquery.js and 1 other location - About 1 hr to fix
    benchmark/scan/assets/jquery.js on lines 5530..5534

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

    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 off has 26 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        off: function( types, selector, fn ) {
            var handleObj, type;
            if ( types && types.preventDefault && types.handleObj ) {
                // ( event )  dispatched jQuery.Event
                handleObj = types.handleObj;
    Severity: Minor
    Found in benchmark/scan/assets/jquery.js - About 1 hr to fix

      Consider simplifying this complex logical expression.
      Open

                      if ( run_all || (!event.namespace && !handleObj.namespace) || event.namespace_re && event.namespace_re.test( handleObj.namespace ) ) {
      
                          event.data = handleObj.data;
                          event.handleObj = handleObj;
      
      
      Severity: Major
      Found in benchmark/scan/assets/jquery.js - About 1 hr to fix

        Consider simplifying this complex logical expression.
        Open

        if ( jQuery.expr && jQuery.expr.filters ) {
            jQuery.expr.filters.hidden = function( elem ) {
                return ( elem.offsetWidth === 0 && elem.offsetHeight === 0 ) || (!jQuery.support.reliableHiddenOffsets && ((elem.style && elem.style.display) || curCSS( elem, "display" )) === "none");
            };
        
        
        Severity: Major
        Found in benchmark/scan/assets/jquery.js - About 1 hr to fix

          Function access has 7 arguments (exceeds 4 allowed). Consider refactoring.
          Open

              access: function( elems, fn, key, value, chainable, emptyGet, pass ) {
          Severity: Major
          Found in benchmark/scan/assets/jquery.js - About 50 mins to fix

            Function inspectPrefiltersOrTransports has 6 arguments (exceeds 4 allowed). Consider refactoring.
            Open

            function inspectPrefiltersOrTransports( structure, options, originalOptions, jqXHR,
                    dataType /* internal */, inspected /* internal */ ) {
            Severity: Minor
            Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

                                      if ( selMatch[ sel ] ) {
                                          matches.push( handleObj );
                                      }
              Severity: Major
              Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

                Avoid deeply nested control flow statements.
                Open

                                        if ( deleteExpando ) {
                                            delete elem[ internalKey ];
                
                                        } else if ( elem.removeAttribute ) {
                                            elem.removeAttribute( internalKey );
                Severity: Major
                Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

                  Avoid deeply nested control flow statements.
                  Open

                                                      if ( xhrOnUnloadAbort ) {
                                                          delete xhrCallbacks[ handle ];
                                                      }
                  Severity: Major
                  Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

                    Avoid deeply nested control flow statements.
                    Open

                                                        if ( xhr.readyState !== 4 ) {
                                                            xhr.abort();
                                                        }
                    Severity: Major
                    Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

                      Function handlePOSGroup has 6 arguments (exceeds 4 allowed). Consider refactoring.
                      Open

                      function handlePOSGroup( selector, posfilter, argument, contexts, seed, not ) {
                      Severity: Minor
                      Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

                        Avoid deeply nested control flow statements.
                        Open

                                            if ( elements ) {
                                                currentContexts = elements;
                                            }
                        Severity: Major
                        Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

                          Avoid deeply nested control flow statements.
                          Open

                                              if ( !selector ) {
                                                  push.apply( results, slice.call(elements, 0) );
                                              }
                          Severity: Major
                          Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

                            Avoid deeply nested control flow statements.
                            Open

                                                    if ( elem.id !== match[2] ) {
                                                        return rootjQuery.find( selector );
                                                    }
                            Severity: Major
                            Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

                              Avoid deeply nested control flow statements.
                              Open

                                                  if ( elem && elem.parentNode ) {
                                                      // Handle the case where IE, Opera, and Webkit return items
                                                      // by name instead of ID
                                                      if ( elem.id === m ) {
                                                          results.push( elem );
                              Severity: Major
                              Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

                                Avoid deeply nested control flow statements.
                                Open

                                                        while ( className.indexOf(" " + removes[ c ] + " ") > -1 ) {
                                                            className = className.replace( " " + removes[ c ] + " " , " " );
                                                        }
                                Severity: Major
                                Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

                                  Function init has 6 arguments (exceeds 4 allowed). Consider refactoring.
                                  Open

                                      init: function( elem, options, prop, end, easing, unit ) {
                                  Severity: Minor
                                  Found in benchmark/scan/assets/jquery.js - About 45 mins to fix

                                    Avoid deeply nested control flow statements.
                                    Open

                                                        if ( copyIsArray ) {
                                                            copyIsArray = false;
                                                            clone = src && jQuery.isArray(src) ? src : [];
                                    
                                                        } else {
                                    Severity: Major
                                    Found in benchmark/scan/assets/jquery.js - About 45 mins to fix
                                      Severity
                                      Category
                                      Status
                                      Source
                                      Language