Undev/redmine_tagging

View on GitHub
assets/javascripts/tag.js

Summary

Maintainability
D
1 day
Test Coverage

Function tagSuggest has 181 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    $.fn.tagSuggest = function (options) {
        var defaults = {
            'matchClass' : 'tagMatches',
            'tagContainer' : 'div',
            'tagWrap' : 'span',
Severity: Major
Found in assets/javascripts/tag.js - About 7 hrs to fix

    Function handleKeys has 60 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

                function handleKeys(ev) {
                    fromTab = false;
                    var type = ev.type;
                    var resetSelection = false;
    
    
    Severity: Major
    Found in assets/javascripts/tag.js - About 2 hrs to fix

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

                  function showSuggestions(el, key) {
                      workingTags = el.value.split(settings.separator);
                      matches = [];
                      var i, html = '', chosenTags = {}, tagSelected = false;
      
      
      Severity: Minor
      Found in assets/javascripts/tag.js - About 1 hr to fix

        Avoid too many return statements within this function.
        Open

                                    return true;
        Severity: Major
        Found in assets/javascripts/tag.js - About 30 mins to fix

          Avoid too many return statements within this function.
          Open

                                  return true;
          Severity: Major
          Found in assets/javascripts/tag.js - About 30 mins to fix

            Avoid too many return statements within this function.
            Open

                                        return true;
            Severity: Major
            Found in assets/javascripts/tag.js - About 30 mins to fix

              Avoid too many return statements within this function.
              Open

                                      return true;
              Severity: Major
              Found in assets/javascripts/tag.js - About 30 mins to fix

                There are no issues that match your filters.

                Category
                Status