Showing 165 of 196 total issues

Function buildFragment has 74 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    buildFragment: function( elems, context, scripts, selection ) {
        var j, elem, contains,
            tmp, tag, tbody, wrap,
            l = elems.length,

Severity: Major
Found in app/js/jquery.js - About 2 hrs to fix

    Function add has 73 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        add: function( elem, types, handler, data, selector ) {
            var tmp, events, t, handleObjIn,
                special, eventHandle, handleObj,
                handlers, type, namespaces, origType,
                elemData = jQuery._data( elem );
    Severity: Major
    Found in app/js/jquery.js - About 2 hrs to fix

      Function widget has 72 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      $.widget = function( name, base, prototype ) {
          var fullName, existingConstructor, constructor, basePrototype,
              // proxiedPrototype allows the provided prototype to remain unmodified
              // so that it can be used as a mixin for multiple widgets (#8876)
              proxiedPrototype = {},
      Severity: Major
      Found in app/js/jquery.ui.widget.js - About 2 hrs to fix

        Function matcherFromGroupMatchers has 71 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function matcherFromGroupMatchers( elementMatchers, setMatchers ) {
            // A counter to specify which element is currently being matched
            var matcherCachedRuns = 0,
                bySet = setMatchers.length > 0,
                byElement = elementMatchers.length > 0,
        Severity: Major
        Found in app/js/jquery.js - About 2 hrs to fix

          Function done has 67 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                  function done( status, nativeStatusText, responses, headers ) {
                      var isSuccess, success, error, response, modified,
                          statusText = nativeStatusText;
          
                      // Called once
          Severity: Major
          Found in app/js/jquery.js - About 2 hrs to fix

            Function setMatcher has 66 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            function setMatcher( preFilter, selector, matcher, postFilter, postFinder, postSelector ) {
                if ( postFilter && !postFilter[ expando ] ) {
                    postFilter = setMatcher( postFilter );
                }
                if ( postFinder && !postFinder[ expando ] ) {
            Severity: Major
            Found in app/js/jquery.js - About 2 hrs to fix

              Method create has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring.
              Open

                  def self.create(args = {})
                    # Set defaults:
                    args = {
                      filepath: 'public/ggi_family_data.xlsx',
                      # NOTE - The version CANNOT come from the source file, we need to ask what version FALO wants this to be known as, and when we last asked CP about
              Severity: Minor
              Found in lib/ggi/all_families_download.rb - About 2 hrs to fix

              Cognitive Complexity

              Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

              A method's cognitive complexity is based on a few simple rules:

              • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
              • Code is considered more complex for each "break in the linear flow of the code"
              • Code is considered more complex when "flow breaking structures are nested"

              Further reading

              Function superMatcher has 63 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                      superMatcher = function( seed, context, xml, results, expandContext ) {
                          var elem, j, matcher,
                              setMatched = [],
                              matchedCount = 0,
                              i = "0",
              Severity: Major
              Found in app/js/jquery.js - About 2 hrs to fix

                Function Deferred has 60 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    Deferred: function( func ) {
                        var tuples = [
                                // action, add listener, listener list, final state
                                [ "resolve", "done", jQuery.Callbacks("once memory"), "resolved" ],
                                [ "reject", "fail", jQuery.Callbacks("once memory"), "rejected" ],
                Severity: Major
                Found in app/js/jquery.js - About 2 hrs to fix

                  Function CHILD has 59 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                          "CHILD": function( type, what, argument, first, last ) {
                              var simple = type.slice( 0, 3 ) !== "nth",
                                  forward = type.slice( -4 ) !== "last",
                                  ofType = what === "of-type";
                  
                  
                  Severity: Major
                  Found in app/js/jquery.js - About 2 hrs to fix

                    Consider simplifying this complex logical expression.
                    Open

                                            if ( forward && useCache ) {
                                                // Seek `elem` from a previously-cached index
                                                outerCache = parent[ expando ] || (parent[ expando ] = {});
                                                cache = outerCache[ type ] || [];
                                                nodeIndex = cache[0] === dirruns && cache[1];
                    Severity: Critical
                    Found in app/js/jquery.js - About 2 hrs to fix

                      Class Taxon has 22 methods (exceeds 20 allowed). Consider refactoring.
                      Open

                      class Ggi::Taxon
                      
                        attr_accessor :score, :left_value, :right_value
                      
                        # TODO - Taxon probably doesn't need to know about these. Might be worth
                      Severity: Minor
                      Found in lib/ggi/taxon.rb - About 2 hrs to fix

                        Function init has 58 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            init: function( selector, context, rootjQuery ) {
                                var match, elem;
                        
                                // HANDLE: $(""), $(null), $(undefined), $(false)
                                if ( !selector ) {
                        Severity: Major
                        Found in app/js/jquery.js - About 2 hrs to fix

                          Function ajaxConvert has 56 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                          function ajaxConvert( s, response, jqXHR, isSuccess ) {
                              var conv2, current, conv, tmp, prev,
                                  converters = {},
                                  // Work with a copy of dataTypes in case we need to modify it for conversion
                                  dataTypes = s.dataTypes.slice();
                          Severity: Major
                          Found in app/js/jquery.js - About 2 hrs to fix

                            Function domManip has 56 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                domManip: function( args, callback, allowIntersection ) {
                            
                                    // Flatten any nested arrays
                                    args = core_concat.apply( [], args );
                            
                            
                            Severity: Major
                            Found in app/js/jquery.js - About 2 hrs to fix

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

                                          keydown: function( event ) {
                                              if ( this.element.prop( "readOnly" ) ) {
                                                  suppressKeyPress = true;
                                                  suppressInput = true;
                                                  suppressKeyPressRepeat = true;
                              Severity: Major
                              Found in app/js/jquery.ui.autocomplete.js - About 2 hrs to fix

                                Function remove has 51 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                    remove: function( elem, types, handler, selector, mappedTypes ) {
                                        var j, handleObj, tmp,
                                            origCount, t, events,
                                            special, handlers, type,
                                            namespaces, origType,
                                Severity: Major
                                Found in app/js/jquery.js - About 2 hrs to fix

                                  Consider simplifying this complex logical expression.
                                  Open

                                                  if ( ( mappedTypes || origType === handleObj.origType ) &&
                                                      ( !handler || handler.guid === handleObj.guid ) &&
                                                      ( !tmp || tmp.test( handleObj.namespace ) ) &&
                                                      ( !selector || selector === handleObj.selector || selector === "**" && handleObj.selector ) ) {
                                                      handlers.splice( j, 1 );
                                  Severity: Critical
                                  Found in app/js/jquery.js - About 2 hrs to fix

                                    Function internalRemoveData has 49 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                    function internalRemoveData( elem, name, pvt ) {
                                        if ( !jQuery.acceptData( elem ) ) {
                                            return;
                                        }
                                    
                                    
                                    Severity: Minor
                                    Found in app/js/jquery.js - About 1 hr to fix

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

                                      function internalData( elem, name, data, pvt /* Internal Use Only */ ){
                                          if ( !jQuery.acceptData( elem ) ) {
                                              return;
                                          }
                                      
                                      
                                      Severity: Minor
                                      Found in app/js/jquery.js - About 1 hr to fix
                                        Severity
                                        Category
                                        Status
                                        Source
                                        Language