Showing 463 of 531 total issues

Class RuggedRepository has 28 methods (exceeds 20 allowed). Consider refactoring.
Open

class RuggedRepository < Repository
  CONTENT_EXT  = '.content'
  ATTRIBUTE_EXT = '.attributes'

  class Blob
Severity: Minor
Found in plugins/repositories/rugged_repository.rb - About 3 hrs to fix

    Function send has 82 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

                    send: function( headers, complete ) {
    
                        // Get a new xhr
                        var handle, i,
                            xhr = s.xhr();
    Severity: Major
    Found in static/script/01-jquery.js - About 3 hrs to fix

      Function labelled has 81 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          blockstmt('for', function () {
              var f = option.forin, s, t = nexttoken;
              funct['(breakage)'] += 1;
              funct['(loopage)'] += 1;
              advance('(');
      Severity: Major
      Found in tools/jslint.js - About 3 hrs to fix

        Function _keydown has 81 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            _keydown: function( event ) {
                /*jshint maxcomplexity:20*/
                var match, prev, character, skip, regex,
                    preventDefault = true;
        
        
        Severity: Major
        Found in static/script/07-jquery.ui.menu.js - About 3 hrs to fix

          Function labelled has 81 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              blockstmt('for', function () {
                  var f = option.forin, s, t = nexttoken;
                  funct['(breakage)'] += 1;
                  funct['(loopage)'] += 1;
                  advance('(');
          Severity: Major
          Found in tools/jslint/fulljslint.js - About 3 hrs to fix

            Function nud has 80 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                    x.nud = function () {
                        var b, f, i, j, p, seen = {}, t;
                        b = token.line !== nexttoken.line;
                        if (b) {
                            indent += option.indent;
            Severity: Major
            Found in tools/jslint.js - About 3 hrs to fix

              Function nud has 80 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                      x.nud = function () {
                          var b, f, i, j, p, seen = {}, t;
                          b = token.line !== nexttoken.line;
                          if (b) {
                              indent += option.indent;
              Severity: Major
              Found in tools/jslint/fulljslint.js - About 3 hrs to fix

                Method parse has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                Open

                    def self.parse(patch, *h)
                      h = h.size == 1 ? h[0] : Adapter.new(h)
                      src = dst = nil
                      state = :start
                      h.initialize!
                Severity: Minor
                Found in lib/olelo/patch.rb - About 3 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 Sizzle has 77 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 static/script/01-jquery.js - About 3 hrs to fix

                  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 static/script/01-jquery.js - About 2 hrs to fix

                    File helper.rb has 289 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    module Olelo
                      module BlockHelper
                        def blocks
                          @blocks ||= Hash.new('')
                        end
                    Severity: Minor
                    Found in lib/olelo/helper.rb - About 2 hrs to fix

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

                              function openTree(element, path) {
                                  // Cache key for cached json data
                                  var cacheKey = options.cacheStore ? options.cacheStore + ':' + path : null;
                      
                                  // Store json in cache
                      Severity: Major
                      Found in plugins/treeview/script/00-jquery.treeview.js - About 2 hrs to fix

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

                            _create: function() {
                                this.activeMenu = this.element;
                                // flag used to prevent firing of the click handler
                                // as the event bubbles up through nested menus
                                this.mouseHandled = false;
                        Severity: Major
                        Found in static/script/07-jquery.ui.menu.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 static/script/05-jquery.ui.widget.js - About 2 hrs to fix

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

                                itself.data = function () {
                            
                                    var data = {functions: []}, fu, globals, implieds = [], f, i, j,
                                        members = [], n, unused = [], v;
                                    if (itself.errors.length) {
                            Severity: Major
                            Found in tools/jslint.js - About 2 hrs to fix

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

                                  itself.data = function () {
                              
                                      var data = {functions: []}, fu, globals, implieds = [], f, i, j,
                                          members = [], n, unused = [], v;
                                      if (itself.errors.length) {
                              Severity: Major
                              Found in tools/jslint/fulljslint.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 static/script/01-jquery.js - About 2 hrs to fix

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

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

                                    Function add has 70 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 static/script/01-jquery.js - About 2 hrs to fix

                                      Function str has 70 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                          function str(key, holder) {
                                      
                                      // Produce a string from holder[key].
                                      
                                              var i,          // The loop counter.
                                      Severity: Major
                                      Found in static/script/00-json2.js - About 2 hrs to fix
                                        Severity
                                        Category
                                        Status
                                        Source
                                        Language