adobe/brackets

View on GitHub

Showing 3,294 of 3,294 total issues

Function getWidthOrHeight has 38 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function getWidthOrHeight( elem, name, extra ) {

    // Start with offset property
    var val = name === "width" ? elem.offsetWidth : elem.offsetHeight,
        i = name === "width" ? 1 : 0,

    Function entryRenamed has 38 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        FileIndex.prototype.entryRenamed = function (oldPath, newPath, isDirectory) {
            var path,
                renameMap = {},
                oldParentPath = FileUtils.getParentPath(oldPath),
                newParentPath = FileUtils.getParentPath(newPath);
    Severity: Minor
    Found in src/filesystem/FileIndex.js - About 1 hr to fix

      Function startRename has 38 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          ProjectModel.prototype.startRename = function (path, isMoved) {
              var d = new $.Deferred();
              path = _getPathFromFSObject(path);
              if (!path) {
                  path = this._selections.context;
      Severity: Minor
      Found in src/project/ProjectModel.js - About 1 hr to fix

        Function _getPropNameInfo has 38 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            function _getPropNameInfo(ctx) {
                var propName = "",
                    offset = TokenUtils.offsetInToken(ctx),
                    tokenString = ctx.token.string,
                    excludedCharacters = [";", "{", "}"];
        Severity: Minor
        Found in src/language/CSSUtils.js - About 1 hr to fix

          Function update has 38 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              DOMUpdater.prototype.update = function () {
                  var markCache = {},
                      newSubtree = this.build(true, markCache),
                      result = {
                          // default result if we didn't identify a changed portion
          Severity: Minor
          Found in src/language/HTMLInstrumentation.js - About 1 hr to fix

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

                each: function( obj, callback, args ) {
                    var value,
                        i = 0,
                        length = obj.length,
                        isArray = isArraylike( obj );
            Severity: Minor
            Found in src/thirdparty/jquery-2.1.3.js - About 1 hr to fix

              Function update has 38 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  BitmapIndexedNode.prototype.update = function(ownerID, shift, keyHash, key, value, didChangeSize, didAlter) {
                    if (keyHash === undefined) {
                      keyHash = hash(key);
                    }
                    var keyHashFrag = (shift === 0 ? keyHash : keyHash >>> shift) & MASK;
              Severity: Minor
              Found in src/thirdparty/immutable.js - About 1 hr to fix

                Function _addSearchResultsForEntries has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                        function _addSearchResultsForEntries(entries) {
                            var fullPaths = [];
                            return Async.doInParallel(entries, function (entry) {
                                var addedFiles = [],
                                    addedFilePaths = [],
                Severity: Minor
                Found in src/search/FindInFiles.js - About 1 hr to fix

                  Function serverRespToSearchModelFormat has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      function serverRespToSearchModelFormat(msgObj) {
                          var referenceModel = {},
                              result = $.Deferred();
                  
                          if(!(msgObj && msgObj.length && msgObj.cursorPos)) {
                  Severity: Minor
                  Found in src/languageTools/DefaultProviders.js - About 1 hr to fix

                    Function showDialog has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        QuickNavigateDialog.prototype.showDialog = function (prefix, initialString) {
                            if (this.isOpen) {
                                return;
                            }
                            this.isOpen = true;
                    Severity: Minor
                    Found in src/search/QuickOpen.js - About 1 hr to fix

                      Function doJumpToDef has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          JumpToDefProvider.prototype.doJumpToDef = function () {
                              if (!this.client) {
                                  return null;
                              }
                      
                      
                      Severity: Minor
                      Found in src/languageTools/DefaultProviders.js - About 1 hr to fix

                        Identical blocks of code found in 3 locations. Consider refactoring.
                        Open

                                function selectHint(provider, expectedHint, implicitChar) {
                                    var hintList = expectHints(provider, implicitChar);
                                    expect(hintList.indexOf(expectedHint)).not.toBe(-1);
                                    return provider.insertHint(expectedHint);
                                }
                        Severity: Major
                        Found in src/extensions/default/CSSPseudoSelectorHints/unittests.js and 2 other locations - About 1 hr to fix
                        src/extensions/default/CSSAtRuleCodeHints/unittests.js on lines 84..88
                        src/extensions/default/CSSCodeHints/unittests.js on lines 125..129

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

                        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

                        Identical blocks of code found in 3 locations. Consider refactoring.
                        Open

                                function selectHint(provider, expectedHint, implicitChar) {
                                    var hintList = expectHints(provider, implicitChar);
                                    expect(hintList.indexOf(expectedHint)).not.toBe(-1);
                                    return provider.insertHint(expectedHint);
                                }
                        Severity: Major
                        Found in src/extensions/default/CSSCodeHints/unittests.js and 2 other locations - About 1 hr to fix
                        src/extensions/default/CSSAtRuleCodeHints/unittests.js on lines 84..88
                        src/extensions/default/CSSPseudoSelectorHints/unittests.js on lines 90..94

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

                        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

                        Identical blocks of code found in 3 locations. Consider refactoring.
                        Open

                                function selectHint(provider, expectedHint, implicitChar) {
                                    var hintList = expectHints(provider, implicitChar);
                                    expect(hintList.indexOf(expectedHint)).not.toBe(-1);
                                    return provider.insertHint(expectedHint);
                                }
                        Severity: Major
                        Found in src/extensions/default/CSSAtRuleCodeHints/unittests.js and 2 other locations - About 1 hr to fix
                        src/extensions/default/CSSCodeHints/unittests.js on lines 125..129
                        src/extensions/default/CSSPseudoSelectorHints/unittests.js on lines 90..94

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

                        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

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

                                    cover.css({left: -borders[0], top: -borders[1], width: inst.dpDiv.outerWidth(), height: inst.dpDiv.outerHeight()})
                        src/extensions/default/JavaScriptQuickEdit/unittest-files/jquery-ui/ui/jquery.ui.datepicker.js on lines 692..693

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

                        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

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

                                    if ( special.add ) {
                                        special.add.call( elem, handleObj );
                        
                                        if ( !handleObj.handler.guid ) {
                                            handleObj.handler.guid = handler.guid;
                        src/thirdparty/jquery-2.1.3.js on lines 4167..4173

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

                        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 3 locations. Consider refactoring.
                        Open

                                fx.elem.style[attr] = "rgb(" +
                                    Math.max(Math.min(parseInt((fx.pos * (fx.end[0] - fx.start[0])) + fx.start[0], 10), 255), 0) + "," +
                        src/extensions/default/JavaScriptQuickEdit/unittest-files/jquery-ui/ui/jquery.effects.core.js on lines 36..38
                        src/extensions/default/JavaScriptQuickEdit/unittest-files/jquery-ui/ui/jquery.effects.core.js on lines 36..39

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

                        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

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

                                _.each(this.editor.getSelections(), function (sel) {
                                    var tagID = HTMLInstrumentation._getTagIDAtDocumentPos(
                                        editor,
                                        sel.reversed ? sel.end : sel.start
                                    );
                        src/LiveDevelopment/Documents/HTMLDocument.js on lines 194..202

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

                        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 4 locations. Consider refactoring.
                        Open

                                if ( options.my[ 0 ] === "right" ) {
                                    position.left -= elemWidth;
                                } else if ( options.my[ 0 ] === "center" ) {
                                    position.left -= elemWidth / 2;
                                }
                        src/extensions/default/JavaScriptQuickEdit/unittest-files/jquery-ui/ui/jquery.ui.position.js on lines 159..163
                        src/extensions/default/JavaScriptQuickEdit/unittest-files/jquery-ui/ui/jquery.ui.position.js on lines 165..169
                        src/extensions/default/JavaScriptQuickEdit/unittest-files/jquery-ui/ui/jquery.ui.position.js on lines 193..197

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

                        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

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

                                        it("indicates foldable lines in the gutter", function () {
                                            var lineNumbers = foldableLines;
                                            var marks = getGutterFoldMarks();
                                            var gutterNumbers = marks.filter(filterOpen)
                                                .map(getLineNumber);
                        Severity: Major
                        Found in src/extensions/default/CodeFolding/unittests.js and 1 other location - About 1 hr to fix
                        src/extensions/default/CodeFolding/unittests.js on lines 403..409

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

                        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

                        Severity
                        Category
                        Status
                        Source
                        Language