linguisticexplorer/Linguistic-Explorer

View on GitHub

Showing 282 of 417 total issues

File jquery.js has 6373 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/*!
 * jQuery JavaScript Library v1.7.1
 * http://jquery.com/
 *
 * Copyright 2011, John Resig
Severity: Major
Found in public/javascripts/jquery.js - About 2 wks to fix

    Function build has 2112 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        function build() {
            var svg = { };
            
            svg.FRAMERATE = 30;
            svg.MAX_VIRTUAL_PIXELS = 30000;
    Severity: Major
    Found in public/javascripts/canvg.js - About 1 wk to fix

      Method validate! has a Cognitive Complexity of 304 (exceeds 5 allowed). Consider refactoring.
      Open

          def validate!
      
            reset = "\r\e[0K"
      
            @check_users = true
      Severity: Minor
      Found in lib/group_data/validator.rb - About 6 days 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

      File canvg.js has 2164 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      /*
       * canvg.js - Javascript SVG parser and renderer on Canvas
       * MIT Licensed 
       * Gabe Lerner (gabelerner@gmail.com)
       * http://code.google.com/p/canvg/
      Severity: Major
      Found in public/javascripts/canvg.js - About 5 days to fix

        Function jQuery has 592 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        var jQuery = (function() {
        
        // Define a local copy of jQuery
        var jQuery = function( selector, context ) {
                // The jQuery object is actually just the init constructor 'enhanced'
        Severity: Major
        Found in public/javascripts/jquery.js - About 2 days to fix

          Function Gmaps4Rails has 475 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

            this.Gmaps4Rails = (function() {
          
              function Gmaps4Rails() {
                this.map = null;
                this.serviceObject = null;
          Severity: Major
          Found in public/javascripts/gmaps4rails/gmaps4rails.base.js - About 2 days to fix

            Function path has 291 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                    svg.Element.path = function(node) {
                        this.base = svg.Element.PathElementBase;
                        this.base(node);
                                
                        var d = this.attribute('d').value;
            Severity: Major
            Found in public/javascripts/canvg.js - About 1 day to fix

              Function Gmaps4RailsGoogle has 278 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                this.Gmaps4RailsGoogle = (function(_super) {
              
                  __extends(Gmaps4RailsGoogle, _super);
              
                  function Gmaps4RailsGoogle() {
              Severity: Major
              Found in public/javascripts/gmaps4rails/gmaps4rails.googlemaps.js - About 1 day to fix

                Method validate! has 263 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    def validate!
                
                      reset = "\r\e[0K"
                
                      @check_users = true
                Severity: Major
                Found in lib/group_data/validator.rb - About 1 day to fix

                  Function RGBColor has 253 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                  function RGBColor(color_string)
                  {
                      this.ok = false;
                  
                      // strip any leading #
                  Severity: Major
                  Found in public/javascripts/rgbcolor.js - About 1 day to fix

                    Function ajax has 242 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        ajax: function( url, options ) {
                    
                            // If url is an object, simulate pre-1.5 signature
                            if ( typeof url === "object" ) {
                                options = url;
                    Severity: Major
                    Found in public/javascripts/jquery.js - About 1 day to fix

                      Method import! has a Cognitive Complexity of 61 (exceeds 5 allowed). Consider refactoring.
                      Open

                          def import!
                            # RubyProf.measure_mode = RubyProf::ALLOCATIONS
                            # RubyProf.start
                            reset = "\r\e[0K"
                      
                      
                      Severity: Minor
                      Found in lib/group_data/importer.rb - About 1 day 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

                      File gmaps4rails.base.js has 500 lines of code (exceeds 250 allowed). Consider refactoring.
                      Open

                      (function() {
                        var Gmaps;
                      
                        Gmaps = {};
                      
                      
                      Severity: Minor
                      Found in public/javascripts/gmaps4rails/gmaps4rails.base.js - About 1 day to fix

                        Function Gmaps4RailsOpenlayers has 183 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                          this.Gmaps4RailsOpenlayers = (function(_super) {
                        
                            __extends(Gmaps4RailsOpenlayers, _super);
                        
                            function Gmaps4RailsOpenlayers() {
                        Severity: Major
                        Found in public/javascripts/gmaps4rails/gmaps4rails.openlayers.js - About 7 hrs to fix

                          Function Gmaps4RailsBing has 179 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                            this.Gmaps4RailsBing = (function(_super) {
                          
                              __extends(Gmaps4RailsBing, _super);
                          
                              function Gmaps4RailsBing() {
                          Severity: Major
                          Found in public/javascripts/gmaps4rails/gmaps4rails.bing.js - About 7 hrs to fix

                            Method supported_set_values has a Cognitive Complexity of 45 (exceeds 5 allowed). Consider refactoring.
                            Open

                              def supported_set_values
                                @ling = current_group.lings.find(params[:id])
                                @depth = @ling.depth
                                @categories = current_group.categories.at_depth(@depth)
                                session[:category_id] = params[:category_id] if params[:category_id]
                            Severity: Minor
                            Found in app/controllers/lings_controller.rb - About 6 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 path has 166 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                        this.path = function(ctx) {
                                            var pp = this.PathParser;
                                            pp.reset();
                            
                                            var bb = new svg.BoundingBox();
                            Severity: Major
                            Found in public/javascripts/canvg.js - About 6 hrs to fix

                              Method import! has 160 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  def import!
                                    # RubyProf.measure_mode = RubyProf::ALLOCATIONS
                                    # RubyProf.start
                                    reset = "\r\e[0K"
                              
                              
                              Severity: Major
                              Found in lib/group_data/importer.rb - About 6 hrs to fix

                                Function support has 159 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                jQuery.support = (function() {
                                
                                    var support,
                                        all,
                                        a,
                                Severity: Major
                                Found in public/javascripts/jquery.js - About 6 hrs to fix

                                  Function Callbacks has 148 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                  jQuery.Callbacks = function( flags ) {
                                  
                                      // Convert flags from String-formatted to Object-formatted
                                      // (we check in cache first)
                                      flags = flags ? ( flagsCache[ flags ] || createFlags( flags ) ) : {};
                                  Severity: Major
                                  Found in public/javascripts/jquery.js - About 5 hrs to fix
                                    Severity
                                    Category
                                    Status
                                    Source
                                    Language