kennethkalmer/powerdns-on-rails

View on GitHub

Showing 179 of 179 total issues

Function step has 44 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    step: function( gotoEnd ) {
        var t = fxNow || createFxNow(),
            done = true,
            elem = this.elem,
            options = this.options,
Severity: Minor
Found in public/javascripts/jquery.js - About 1 hr to fix

    Function data has 44 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

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

      Function load has 44 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          load: function( url, params, callback ) {
              if ( typeof url !== "string" && _load ) {
                  return _load.apply( this, arguments );
      
              // Don't do a request if no elements are being requested
      Severity: Minor
      Found in public/javascripts/jquery.js - About 1 hr to fix

        Function handleRemote has 43 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            handleRemote: function(element) {
              var method, url, data,
                crossDomain = element.data('cross-domain') || null,
                dataType = element.data('type') || ($.ajaxSettings && $.ajaxSettings.dataType);
        
        
        Severity: Minor
        Found in public/javascripts/jquery_ujs.js - About 1 hr to fix

          Function data has 41 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              data: function( key, value ) {
                  var data = null;
          
                  if ( typeof key === "undefined" ) {
                      if ( this.length ) {
          Severity: Minor
          Found in public/javascripts/jquery.js - About 1 hr to fix

            Function extend has 40 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            jQuery.extend = jQuery.fn.extend = function() {
                var options, name, src, copy, copyIsArray, clone,
                    target = arguments[0] || {},
                    i = 1,
                    length = arguments.length,
            Severity: Minor
            Found in public/javascripts/jquery.js - About 1 hr to fix

              Function attr has 40 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  attr: function( elem, name, value, pass ) {
                      var nType = elem.nodeType;
                      
                      // don't get/set attributes on text, comment and attribute nodes
                      if ( !elem || nType === 3 || nType === 8 || nType === 2 ) {
              Severity: Minor
              Found in public/javascripts/jquery.js - About 1 hr to fix

                Function val has 37 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    val: function( value ) {
                        var hooks, ret,
                            elem = this[0];
                        
                        if ( !arguments.length ) {
                Severity: Minor
                Found in public/javascripts/jquery.js - About 1 hr to fix

                  Function fix has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      fix: function( event ) {
                          if ( event[ jQuery.expando ] ) {
                              return event;
                          }
                  
                  
                  Severity: Minor
                  Found in public/javascripts/jquery.js - About 1 hr to fix

                    Consider simplifying this complex logical expression.
                    Open

                                if ( match[1] === "nth" ) {
                                    if ( !match[2] ) {
                                        Sizzle.error( match[0] );
                                    }
                    
                    
                    Severity: Critical
                    Found in public/javascripts/jquery.js - About 1 hr to fix

                      Consider simplifying this complex logical expression.
                      Open

                          if ( args.length === 1 && typeof args[0] === "string" && args[0].length < 512 && doc === document &&
                              args[0].charAt(0) === "<" && !rnocache.test( args[0] ) && (jQuery.support.checkClone || !rchecked.test( args[0] )) ) {
                      
                              cacheable = true;
                      
                      
                      Severity: Critical
                      Found in public/javascripts/jquery.js - About 1 hr to fix

                        Function each has 33 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            each: function( object, callback, args ) {
                                var name, i = 0,
                                    length = object.length,
                                    isObj = length === undefined || jQuery.isFunction( object );
                        
                        
                        Severity: Minor
                        Found in public/javascripts/jquery.js - About 1 hr to fix

                          Function jsAnimateOpacity has 33 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                              function jsAnimateOpacity(level,callback){
                                  var interval;
                                  var opacity;
                          
                                  if (level === 1) {
                          Severity: Minor
                          Found in public/javascripts/humane.js - About 1 hr to fix

                            Function setOffset has 32 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                setOffset: function( elem, options, i ) {
                                    var position = jQuery.css( elem, "position" );
                            
                                    // set position first, in-case top/left are set even on static elem
                                    if ( position === "static" ) {
                            Severity: Minor
                            Found in public/javascripts/jquery.js - About 1 hr to fix

                              Method validate_record_template has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
                              Open

                                def validate_record_template #:nodoc:
                                  unless self.record_type.blank?
                                    record = build
                                    record.errors.each do |k,v|
                                      # skip associations we don't have, validations we don't care about
                              Severity: Minor
                              Found in app/models/record_template.rb - About 1 hr 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 when has 30 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  when: function( firstParam ) {
                                      var args = arguments,
                                          i = 0,
                                          length = args.length,
                                          count = length,
                              Severity: Minor
                              Found in public/javascripts/jquery.js - About 1 hr to fix

                                Function dirCheck has 30 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                function dirCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) {
                                    for ( var i = 0, l = checkSet.length; i < l; i++ ) {
                                        var elem = checkSet[i];
                                
                                        if ( elem ) {
                                Severity: Minor
                                Found in public/javascripts/jquery.js - About 1 hr to fix

                                  Function cleanData has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      cleanData: function( elems ) {
                                          var data, id, cache = jQuery.cache, internalKey = jQuery.expando, special = jQuery.event.special,
                                              deleteExpando = jQuery.support.deleteExpando;
                                  
                                          for ( var i = 0, elem; (elem = elems[i]) != null; i++ ) {
                                  Severity: Minor
                                  Found in public/javascripts/jquery.js - About 1 hr to fix

                                    Function promise has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                        promise: function( type, object ) {
                                            if ( typeof type !== "string" ) {
                                                object = type;
                                                type = undefined;
                                            }
                                    Severity: Minor
                                    Found in public/javascripts/jquery.js - About 1 hr to fix

                                      Function offset has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                          jQuery.fn.offset = function( options ) {
                                              var elem = this[0], box;
                                      
                                              if ( options ) {
                                                  return this.each(function( i ) {
                                      Severity: Minor
                                      Found in public/javascripts/jquery.js - About 1 hr to fix
                                        Severity
                                        Category
                                        Status
                                        Source
                                        Language