neyric/wireit

View on GitHub

Showing 497 of 497 total issues

Similar blocks of code found in 47 locations. Consider refactoring.
Open

        {
            "name": "Start Compensation Event",
            "category": "startevent",
            "container": {
              "xtype":"Y.ImageContainer", 
Severity: Major
Found in sandbox/editor-examples/BPMN-editor/bpmn-2.0.js and 46 other locations - About 2 hrs to fix
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 39..51
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 53..65
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 67..79
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 81..93
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 114..126
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 128..140
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 142..154
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 156..168
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 189..201
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 203..215
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 235..247
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 267..279
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 281..293
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 295..307
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 327..339
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 341..353
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 355..367
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 369..381
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 397..409
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 411..423
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 425..437
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 439..451
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 471..483
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 485..497
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 499..511
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 513..525
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 527..539
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 541..553
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 555..567
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 569..581
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 582..594
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 596..608
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 628..640
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 642..654
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 656..668
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 670..682
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 684..696
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 698..710
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 730..742
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 744..756
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 758..770
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 772..784
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 786..798
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 800..812
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 814..826
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 828..840

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

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

        {
            "name": "Cancel End Event",
            "category": "endevent",
            "container": {
              "xtype":"Y.ImageContainer", 
Severity: Major
Found in sandbox/editor-examples/BPMN-editor/bpmn-2.0.js and 46 other locations - About 2 hrs to fix
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 39..51
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 53..65
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 67..79
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 81..93
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 114..126
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 128..140
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 142..154
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 156..168
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 189..201
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 203..215
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 235..247
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 267..279
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 281..293
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 295..307
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 327..339
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 341..353
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 355..367
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 369..381
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 383..395
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 397..409
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 411..423
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 425..437
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 439..451
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 471..483
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 485..497
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 499..511
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 513..525
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 527..539
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 541..553
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 555..567
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 569..581
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 582..594
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 596..608
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 628..640
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 642..654
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 656..668
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 670..682
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 684..696
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 698..710
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 730..742
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 744..756
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 772..784
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 786..798
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 800..812
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 814..826
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 828..840

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

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

        {
            "name": "End Signal Event",
            "category": "endevent",
            "container": {
              "xtype":"Y.ImageContainer", 
Severity: Major
Found in sandbox/editor-examples/BPMN-editor/bpmn-2.0.js and 46 other locations - About 2 hrs to fix
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 39..51
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 53..65
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 67..79
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 81..93
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 114..126
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 128..140
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 142..154
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 156..168
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 189..201
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 203..215
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 235..247
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 267..279
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 281..293
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 295..307
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 327..339
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 341..353
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 355..367
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 369..381
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 383..395
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 397..409
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 411..423
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 425..437
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 439..451
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 471..483
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 485..497
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 499..511
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 513..525
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 527..539
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 541..553
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 555..567
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 569..581
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 582..594
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 596..608
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 628..640
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 642..654
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 656..668
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 670..682
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 684..696
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 698..710
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 730..742
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 744..756
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 758..770
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 772..784
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 800..812
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 814..826
sandbox/editor-examples/BPMN-editor/bpmn-2.0.js on lines 828..840

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

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

Function getOverridesFromUI has 56 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    getOverridesFromUI: function(containerUIMap, groupUIMap)
    {
        containerOverrides = [];
        groupOverrides = [];
        
Severity: Major
Found in sandbox/grouping/js/GroupUtils.js - About 2 hrs to fix

    Function LocalStorageSync has 56 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function LocalStorageSync(key) {
        var localStorage;
    
        if (!key) {
            Y.error('No storage key specified.');
    Severity: Major
    Found in src/wireit-app/js/local-storage-sync.js - About 2 hrs to fix

      Function LocalStorageSync has 56 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function LocalStorageSync(key) {
          var localStorage;
      
          if (!key) {
              Y.error('No storage key specified.');
      Severity: Major
      Found in build/wireit-all/wireit-all.js - About 2 hrs to fix

        Function LocalStorageSync has 56 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function LocalStorageSync(key) {
            var localStorage;
        
            if (!key) {
                Y.error('No storage key specified.');
        Severity: Major
        Found in build/wireit-app/wireit-app-debug.js - About 2 hrs to fix

          Function LocalStorageSync has 56 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          function LocalStorageSync(key) {
              var localStorage;
          
              if (!key) {
                  Y.error('No storage key specified.');
          Severity: Major
          Found in build/wireit-app/wireit-app.js - About 2 hrs to fix

            Function LocalStorageSync has 56 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            function LocalStorageSync(key) {
                var localStorage;
            
                if (!key) {
                    Y.error('No storage key specified.');
            Severity: Major
            Found in build/wireit-all/wireit-all-debug.js - About 2 hrs to fix

              Function render has 53 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                 render: function() {
                    Y.LayerContainer.superclass.render.call(this);
              
                       this.subLayer = new Y.Layer({layerMap: false, parentEl: this.bodyEl});
              
              
              Severity: Major
              Found in sandbox/layer-container/layer-container.js - About 2 hrs to fix

                Function xpathParseInit has 53 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                function xpathParseInit() {
                  if (xpathRules.length) {
                    return;
                  }
                
                
                Severity: Major
                Found in sandbox/grouping/examples/sawire/xml/xpath.js - About 2 hrs to fix

                  Function xpathMatchStack has 53 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                  function xpathMatchStack(stack, pattern) {
                  
                    // NOTE(mesch): The stack matches for variable cardinality are
                    // greedy but don't do backtracking. This would be an issue only
                    // with rules of the form A* A, i.e. with an element with variable
                  Severity: Major
                  Found in sandbox/grouping/examples/sawire/xml/xpath.js - About 2 hrs to fix

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

                            var top = parseInt(dbWire.layer.containers[i].el.style.top.substr(0,dbWire.layer.containers[i].el.style.top.length-2),10);
                    Severity: Major
                    Found in sandbox/clearExplode.js and 1 other location - About 2 hrs to fix
                    sandbox/clearExplode.js on lines 14..14

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

                    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.axis == xpathAxis.FOLLOWING) {
                        for (var n = input; n; n = n.parentNode) {
                          for (var nn = n.nextSibling; nn; nn = nn.nextSibling) {
                            nodelist.push(nn);
                            xpathCollectDescendants(nodelist, nn);
                    Severity: Major
                    Found in sandbox/grouping/examples/sawire/xml/xpath.js and 1 other location - About 2 hrs to fix
                    sandbox/grouping/examples/sawire/xml/xpath.js on lines 795..813

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

                    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 (this.args.length > 0) {
                          s = this.args[0].evaluate(ctx).stringValue();
                        } else {
                          s = new NodeSetValue([ ctx.node ]).stringValue();
                        }
                    Severity: Major
                    Found in sandbox/grouping/examples/sawire/xml/xpath.js and 1 other location - About 2 hrs to fix
                    sandbox/grouping/examples/sawire/xml/xpath.js on lines 1093..1097

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

                    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

                           var left = parseInt(dbWire.layer.containers[i].el.style.left.substr(0,dbWire.layer.containers[i].el.style.left.length-2),10);
                    Severity: Major
                    Found in sandbox/clearExplode.js and 1 other location - About 2 hrs to fix
                    sandbox/clearExplode.js on lines 15..15

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

                    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.axis == xpathAxis.PRECEDING) {
                        for (var n = input; n; n = n.parentNode) {
                          for (var nn = n.previousSibling; nn; nn = nn.previousSibling) {
                            nodelist.push(nn);
                            xpathCollectDescendantsReverse(nodelist, nn);
                    Severity: Major
                    Found in sandbox/grouping/examples/sawire/xml/xpath.js and 1 other location - About 2 hrs to fix
                    sandbox/grouping/examples/sawire/xml/xpath.js on lines 774..813

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

                    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

                            if (xNoScroll < self.scrollThreshold) {
                                // Near the left edge so scroll left
                                self.directions.left = true;
                            }
                            else if ((rect.right - event.clientX) < self.scrollThreshold) {
                    Severity: Major
                    Found in sandbox/grouping/js/RubberBand.js and 1 other location - About 2 hrs to fix
                    sandbox/grouping/js/RubberBand.js on lines 38..45

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

                    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 (this.args.length > 0) {
                          s = this.args[0].evaluate(ctx).stringValue();
                        } else {
                          s = new NodeSetValue([ ctx.node ]).stringValue();
                        }
                    Severity: Major
                    Found in sandbox/grouping/examples/sawire/xml/xpath.js and 1 other location - About 2 hrs to fix
                    sandbox/grouping/examples/sawire/xml/xpath.js on lines 1103..1107

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

                    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

                            if (yNoScroll < self.scrollThreshold) {
                                // Near top
                                self.directions.up = true;
                            }
                            else if ((rect.bottom - event.clientY) < self.scrollThreshold) {
                    Severity: Major
                    Found in sandbox/grouping/js/RubberBand.js and 1 other location - About 2 hrs to fix
                    sandbox/grouping/js/RubberBand.js on lines 29..36

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

                    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