adobe/brackets

View on GitHub

Showing 3,294 of 3,294 total issues

Function addTextDelete has 27 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        var addTextDelete = function () {
            var prev = prevNode();
            if (prev && !prev.children) {
                newEdit = {
                    type: "textReplace",
Severity: Minor
Found in src/language/HTMLDOMDiff.js - About 1 hr to fix

    Function _applySingleChangeToRange has 27 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        TextRange.prototype._applySingleChangeToRange = function (change) {
            // console.log(this + " applying change to (" +
            //         (change.from && (change.from.line+","+change.from.ch)) + " - " +
            //         (change.to && (change.to.line+","+change.to.ch)) + ")");
    
    
    Severity: Minor
    Found in src/document/TextRange.js - About 1 hr to fix

      Function updateVNode has 27 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

        function updateVNode(node, ownerID, level, index, value, didAlter) {
          var idx = (index >>> level) & MASK;
          var nodeHas = node && idx < node.array.length;
          if (!nodeHas && value === undefined) {
            return node;
      Severity: Minor
      Found in src/thirdparty/immutable.js - About 1 hr to fix

        Function make has 27 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function make () {
          // don't do it more than once.
          if (this._made) return
        
          var pattern = this.pattern
        Severity: Minor
        Found in src/thirdparty/globmatch.js - About 1 hr to fix

          Function propFilter has 27 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          function propFilter( props, specialEasing ) {
              var index, name, easing, value, hooks;
          
              // camelCase, specialEasing and expand cssHook pass
              for ( index in props ) {
          Severity: Minor
          Found in src/thirdparty/jquery-2.1.3.js - About 1 hr to fix

            Function close has 27 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                ModalBar.prototype.close = function (restoreScrollPos, animate, _reason) {
                    var result = new $.Deferred(),
                        self = this;
            
                    if (restoreScrollPos === undefined) {
            Severity: Minor
            Found in src/widgets/ModalBar.js - About 1 hr to fix

              Function setVisible has 27 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  function setVisible(curEditor, visible) {
                      // short-circuit no-ops
                      if ((visible && curEditor === editor) || (!visible && !editor)) {
                          return;
                      }
              Severity: Minor
              Found in src/search/ScrollTrackMarkers.js - About 1 hr to fix

                Function setInspectionResults has 27 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    LintingProvider.prototype.setInspectionResults = function (msgObj) {
                        let diagnostics = msgObj.diagnostics,
                            filePath = PathConverters.uriToPath(msgObj.uri),
                            errors = [];
                
                
                Severity: Minor
                Found in src/languageTools/DefaultProviders.js - About 1 hr to fix

                  Function prioritizeOpenFile has 27 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      function prioritizeOpenFile(files, firstFile) {
                          var workingSetFiles = MainViewManager.getWorkingSet(MainViewManager.ALL_PANES),
                              workingSetFileFound = {},
                              fileSetWithoutWorkingSet = [],
                              startingWorkingFileSet = [],
                  Severity: Minor
                  Found in src/search/FindUtils.js - About 1 hr to fix

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

                                    if (c === ">") {
                                        this._state = TEXT;
                                        this._emitSpecialToken("opentagend", this._index + 1, _clonePos(this._indexPos, 1));
                                        this._startSection(1);
                                    } else if (c === "/") {
                    Severity: Major
                    Found in src/language/HTMLTokenizer.js and 1 other location - About 1 hr to fix
                    src/language/HTMLTokenizer.js on lines 375..387

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

                    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

                            do {
                                index = _.findIndex(_mruList, compare);
                                if (index !== -1) {
                                    _mruList.splice(index, 1);
                                }
                    Severity: Major
                    Found in src/view/MainViewManager.js and 1 other location - About 1 hr to fix
                    src/view/MainViewManager.js on lines 873..878

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

                    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 (c === ">") {
                                        this._state = TEXT;
                                        this._emitSpecialToken("opentagend", this._index + 1, _clonePos(this._indexPos, 1));
                                        this._startSection(1);
                                    } else if (c === "/") {
                    Severity: Major
                    Found in src/language/HTMLTokenizer.js and 1 other location - About 1 hr to fix
                    src/language/HTMLTokenizer.js on lines 293..306

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

                    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

                                                dialogs.push({
                                                    dialog: DefaultDialogs.DIALOG_ID_ERROR,
                                                    title: Strings.EXTENSION_MANAGER_UPDATE,
                                                    message: StringUtils.format(Strings.EXTENSION_MANAGER_UPDATE_ERROR, ids.join(", "))
                                                });
                    Severity: Major
                    Found in src/extensibility/ExtensionManagerDialog.js and 2 other locations - About 1 hr to fix
                    src/extensibility/ExtensionManagerDialog.js on lines 158..162
                    src/extensibility/ExtensionManagerDialog.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 56.

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

                                } else if (this._state === BEFORE_STYLE_4) {
                                    if (c === "/" || c === ">" || isWhitespace(c)) {
                                        this._special = 2;
                                    }
                                    this._state = IN_TAG_NAME;
                    Severity: Major
                    Found in src/language/HTMLTokenizer.js and 1 other location - About 1 hr to fix
                    src/language/HTMLTokenizer.js on lines 570..670

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

                    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

                            do {
                                index = _.findIndex(_mruList, compare);
                                if (index !== -1) {
                                    _mruList.splice(index, 1);
                                }
                    Severity: Major
                    Found in src/view/MainViewManager.js and 1 other location - About 1 hr to fix
                    src/view/MainViewManager.js on lines 788..793

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

                    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

                                                dialogs.push({
                                                    dialog: DefaultDialogs.DIALOG_ID_ERROR,
                                                    title: Strings.EXTENSION_MANAGER_REMOVE,
                                                    message: StringUtils.format(Strings.EXTENSION_MANAGER_REMOVE_ERROR, ids.join(", "))
                                                });
                    Severity: Major
                    Found in src/extensibility/ExtensionManagerDialog.js and 2 other locations - About 1 hr to fix
                    src/extensibility/ExtensionManagerDialog.js on lines 181..185
                    src/extensibility/ExtensionManagerDialog.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 56.

                    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

                                                dialogs.push({
                                                    dialog: DefaultDialogs.DIALOG_ID_ERROR,
                                                    title: Strings.EXTENSION_MANAGER_DISABLE,
                                                    message: StringUtils.format(Strings.EXTENSION_MANAGER_DISABLE_ERROR, ids.join(", "))
                                                });
                    Severity: Major
                    Found in src/extensibility/ExtensionManagerDialog.js and 2 other locations - About 1 hr to fix
                    src/extensibility/ExtensionManagerDialog.js on lines 158..162
                    src/extensibility/ExtensionManagerDialog.js on lines 181..185

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

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

                            percent: {
                                // [negativePattern, positivePattern]
                                //   negativePattern: one of "-n %|-n%|-%n|%-n|%n-|n-%|n%-|-% n|n %-|% n-|% -n|n- %"
                                //   positivePattern: one of "n %|n%|%n|% n"
                                pattern: [ "-n %", "n %" ],
                    src/extensions/default/JavaScriptQuickEdit/unittest-files/jquery-ui/external/globalize.js on lines 145..161

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

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

                                } else if (this._state === BEFORE_SCRIPT_5) {
                                    if (c === "/" || c === ">" || isWhitespace(c)) {
                                        this._special = 1;
                                    }
                                    this._state = IN_TAG_NAME;
                    Severity: Major
                    Found in src/language/HTMLTokenizer.js and 1 other location - About 1 hr to fix
                    src/language/HTMLTokenizer.js on lines 634..670

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

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

                                    "fullFunctionScope": {
                                        "start": current.cm.posFromIndex(loc.fullFunctionScope.start),
                                        "end": current.cm.posFromIndex(loc.fullFunctionScope.end)
                                    },
                    src/extensions/default/JavaScriptRefactoring/WrapSelection.js on lines 189..192

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

                    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