adobe/brackets

View on GitHub

Showing 1,485 of 3,294 total issues

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

    function presentConflicts(title) {

        var allConflicts = editConflicts.concat(deleteConflicts);

        function presentConflict(docInfo, i) {
Severity: Major
Found in src/project/FileSyncManager.js - About 3 hrs to fix

    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 src/thirdparty/jquery-2.1.3.js - About 3 hrs to fix

      File FileSystemEntry.js has 308 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      /*
       * Copyright (c) 2013 - present Adobe Systems Incorporated. All rights reserved.
       *
       * Permission is hereby granted, free of charge, to any person obtaining a
       * copy of this software and associated documentation files (the "Software"),
      Severity: Minor
      Found in src/filesystem/FileSystemEntry.js - About 3 hrs to fix

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

            function handleExtractToVariable() {
                var editor = EditorManager.getActiveEditor();
        
                if (editor.getSelections().length > 1) {
                    editor.displayErrorMessageAtCursor(Strings.ERROR_EXTRACTTO_VARIABLE_MULTICURSORS);
        Severity: Major
        Found in src/extensions/default/JavaScriptRefactoring/ExtractToVariable.js - About 3 hrs to fix

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

                  function doAnimation() {
                      // XXX 'this' does not always have a nodeName when running the
                      // test suite
          
                      if ( optall.queue === false ) {

            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 src/thirdparty/jquery-2.1.3.js - About 3 hrs to fix

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

                  _create: function() {
                      this.activeMenu = this.element;
                      this.element
                          .uniqueId()
                          .addClass( "ui-menu ui-widget ui-widget-content ui-corner-all" )

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

                    _keydown: function( event ) {
                        var match, prev, character, skip,
                            preventDefault = true;
                
                        function escape( value ) {

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

                      blockstmt('for', function () {
                          var s, t = nexttoken;
                          funct['(breakage)'] += 1;
                          funct['(loopage)'] += 1;
                          advance('(');

                    File ViewUtils.js has 305 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    /*
                     * Copyright (c) 2012 - present Adobe Systems Incorporated. All rights reserved.
                     *
                     * Permission is hereby granted, free of charge, to any person obtaining a
                     * copy of this software and associated documentation files (the "Software"),
                    Severity: Minor
                    Found in src/utils/ViewUtils.js - About 3 hrs to fix

                      File JSUtils.js has 305 lines of code (exceeds 250 allowed). Consider refactoring.
                      Open

                      /*
                       * Copyright (c) 2012 - present Adobe Systems Incorporated. All rights reserved.
                       *
                       * Permission is hereby granted, free of charge, to any person obtaining a
                       * copy of this software and associated documentation files (the "Software"),
                      Severity: Minor
                      Found in src/language/JSUtils.js - About 3 hrs to fix

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

                        define(function LiveCSSDocumentModule(require, exports, module) {
                            "use strict";
                        
                            var _               = require("thirdparty/lodash"),
                                CSSUtils        = require("language/CSSUtils"),
                        Severity: Major
                        Found in src/LiveDevelopment/MultiBrowserImpl/documents/LiveCSSDocument.js - About 3 hrs to fix

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

                              function doFold(cm, pos, options, force) {
                                  options = options || {};
                                  force = force || "fold";
                                  if (typeof pos === "number") {
                                      pos = CodeMirror.Pos(pos, 0);
                          Severity: Major
                          Found in src/extensions/default/CodeFolding/foldhelpers/foldcode.js - About 3 hrs to fix

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

                                finish: function() {
                                    config.current = this;
                                    if ( this.expected != null && this.expected != this.assertions.length ) {
                                        QUnit.pushFailure( "Expected " + this.expected + " assertions, but " + this.assertions.length + " were run", this.stack );
                                    } else if ( this.expected == null && !this.assertions.length ) {

                              File UpdateNotification.js has 303 lines of code (exceeds 250 allowed). Consider refactoring.
                              Open

                              /*
                               * Copyright (c) 2012 - present Adobe Systems Incorporated. All rights reserved.
                               *
                               * Permission is hereby granted, free of charge, to any person obtaining a
                               * copy of this software and associated documentation files (the "Software"),
                              Severity: Minor
                              Found in src/utils/UpdateNotification.js - About 3 hrs to fix

                                Function CSSAgent has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring.
                                Open

                                define(function CSSAgent(require, exports, module) {
                                    "use strict";
                                
                                    var _ = require("thirdparty/lodash");
                                
                                
                                Severity: Minor
                                Found in src/LiveDevelopment/Agents/CSSAgent.js - 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 onConnectFail has 81 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                        Inspector.connectToURL(launcherUrl).fail(function onConnectFail(err) {
                                            if (err === "CANCEL") {
                                                _openDeferred.reject(err);
                                                return;
                                            }
                                Severity: Major
                                Found in src/LiveDevelopment/LiveDevelopment.js - About 3 hrs to fix

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

                                          function presentConflict(docInfo, i) {
                                              var result = new $.Deferred(),
                                                  promise = result.promise(),
                                                  doc = docInfo.doc,
                                                  fileTime = docInfo.fileTime;
                                  Severity: Major
                                  Found in src/project/FileSyncManager.js - About 3 hrs to fix

                                    File AppshellFileSystem.js has 301 lines of code (exceeds 250 allowed). Consider refactoring.
                                    Open

                                    /*
                                     * Copyright (c) 2013 - present Adobe Systems Incorporated. All rights reserved.
                                     *
                                     * Permission is hereby granted, free of charge, to any person obtaining a
                                     * copy of this software and associated documentation files (the "Software"),
                                    Severity: Minor
                                    Found in src/filesystem/impls/appshell/AppshellFileSystem.js - About 3 hrs to fix

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

                                          CodeHintList.prototype._keydownHook = function (event, isFakeKeydown) {
                                              var keyCode,
                                                  self = this;
                                      
                                              // positive distance rotates down; negative distance rotates up
                                      Severity: Major
                                      Found in src/editor/CodeHintList.js - About 3 hrs to fix
                                        Severity
                                        Category
                                        Status
                                        Source
                                        Language