suitmedia/suitcoda

View on GitHub

Showing 784 of 784 total issues

Function setDocument has 218 lines of code (exceeds 25 allowed). Consider refactoring.
Open

setDocument = Sizzle.setDocument = function( node ) {
    var hasCompare, parent,
        doc = node ? node.ownerDocument || node : preferredDoc;

    // If no document and documentElement is available, return
Severity: Major
Found in _frontend/assets/js/vendor/jquery.min.js - About 1 day to fix

    Function setDocument has 218 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    setDocument = Sizzle.setDocument = function( node ) {
        var hasCompare, parent,
            doc = node ? node.ownerDocument || node : preferredDoc;
    
        // If no document and documentElement is available, return
    Severity: Major
    Found in _frontend/dev/js/vendor/jquery.js - About 1 day to fix

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

          public function testRunJsResultReader()
          {
              $json = json_encode([
                  'url' => 'https://example.com/',
                  'name' => 'Js Linter',
      Severity: Major
      Found in tests/Supports/ResultReaderTest.php and 2 other locations - About 1 day to fix
      tests/Supports/ResultReaderTest.php on lines 300..329
      tests/Supports/ResultReaderTest.php on lines 359..388

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

      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

          public function testRunHtmlResultReader()
          {
              $json = json_encode([
                  'url' => 'https://example.com/',
                  'name' => 'HTML Linter',
      Severity: Major
      Found in tests/Supports/ResultReaderTest.php and 2 other locations - About 1 day to fix
      tests/Supports/ResultReaderTest.php on lines 359..388
      tests/Supports/ResultReaderTest.php on lines 418..447

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

      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

          public function testRunCssResultReader()
          {
              $json = json_encode([
                  'url' => 'https://example.com/',
                  'name' => 'Css Linter',
      Severity: Major
      Found in tests/Supports/ResultReaderTest.php and 2 other locations - About 1 day to fix
      tests/Supports/ResultReaderTest.php on lines 300..329
      tests/Supports/ResultReaderTest.php on lines 418..447

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

      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

      FastClick.prototype.onMouse = function(event) {
          'use strict';
      
          // If a target element was never set (because a touch event was never fired) allow the event
          if (!this.targetElement) {
      Severity: Major
      Found in _frontend/assets/js/vendor/fastclick.min.js and 1 other location - About 7 hrs to fix
      _frontend/dev/js/vendor/fastclick.js on lines 598..638

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

      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

      FastClick.prototype.onMouse = function(event) {
          'use strict';
      
          // If a target element was never set (because a touch event was never fired) allow the event
          if (!this.targetElement) {
      Severity: Major
      Found in _frontend/dev/js/vendor/fastclick.js and 1 other location - About 7 hrs to fix
      _frontend/assets/js/vendor/fastclick.min.js on lines 598..638

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

      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

      FastClick.prototype.destroy = function() {
          'use strict';
          var layer = this.layer;
      
          if (this.deviceIsAndroid) {
      Severity: Major
      Found in _frontend/assets/js/vendor/fastclick.min.js and 1 other location - About 7 hrs to fix
      _frontend/dev/js/vendor/fastclick.js on lines 682..697

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

      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

      FastClick.prototype.destroy = function() {
          'use strict';
          var layer = this.layer;
      
          if (this.deviceIsAndroid) {
      Severity: Major
      Found in _frontend/dev/js/vendor/fastclick.js and 1 other location - About 7 hrs to fix
      _frontend/assets/js/vendor/fastclick.min.js on lines 682..697

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

      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

      File ResultReaderTest.php has 469 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      <?php
      
      namespace SuitTests\Supports;
      
      use Illuminate\Foundation\Testing\DatabaseTransactions;
      Severity: Minor
      Found in tests/Supports/ResultReaderTest.php - About 7 hrs to fix

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

                w3ResultError = horseman.evaluate( function (selector) {
                        
                        var $results    = $(selector);
                        var $errors     = $results.find('.msg_err');
                        var $warnings   = $results.find('.msg_warn');
        Severity: Major
        Found in linter/htmlHorseman.js and 1 other location - About 7 hrs to fix
        linter/htmlHorseman.js on lines 141..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 176.

        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

                w3ResultWarning = horseman.evaluate( function (selector) {
                        
                        var $results    = $(selector);
                        var $errors     = $results.find('.msg_err');
                        var $warnings   = $results.find('.msg_warn');
        Severity: Major
        Found in linter/htmlHorseman.js and 1 other location - About 7 hrs to fix
        linter/htmlHorseman.js on lines 119..139

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

        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

        FastClick.prototype.sendClick = function(targetElement, event) {
            'use strict';
            var clickEvent, touch;
        
            // On some Android devices activeElement needs to be blurred otherwise the synthetic click will have no effect (#24)
        Severity: Major
        Found in _frontend/assets/js/vendor/fastclick.min.js and 1 other location - About 6 hrs to fix
        _frontend/dev/js/vendor/fastclick.js on lines 275..291

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

        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

        FastClick.prototype.sendClick = function(targetElement, event) {
            'use strict';
            var clickEvent, touch;
        
            // On some Android devices activeElement needs to be blurred otherwise the synthetic click will have no effect (#24)
        Severity: Major
        Found in _frontend/dev/js/vendor/fastclick.js and 1 other location - About 6 hrs to fix
        _frontend/assets/js/vendor/fastclick.min.js on lines 275..291

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

        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

        FastClick.notNeeded = function(layer) {
            'use strict';
            var metaViewport;
        
            // Devices that don't support touch don't need FastClick
        Severity: Major
        Found in _frontend/dev/js/vendor/fastclick.js and 1 other location - About 6 hrs to fix
        _frontend/assets/js/vendor/fastclick.min.js on lines 705..735

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

        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

        FastClick.notNeeded = function(layer) {
            'use strict';
            var metaViewport;
        
            // Devices that don't support touch don't need FastClick
        Severity: Major
        Found in _frontend/assets/js/vendor/fastclick.min.js and 1 other location - About 6 hrs to fix
        _frontend/dev/js/vendor/fastclick.js on lines 705..735

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

        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 run has 162 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                        YSLOW.phantomjs.run = function() {
                            try {
                                var D, z, A, u, K = document,
                                    F = YSLOW,
                                    x = new F.context(K),
        Severity: Major
        Found in performance/yslow.js - About 6 hrs to fix

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

          FastClick.prototype.updateScrollParent = function(targetElement) {
              'use strict';
              var scrollParent, parentElement;
          
              scrollParent = targetElement.fastClickScrollParent;
          Severity: Major
          Found in _frontend/assets/js/vendor/fastclick.min.js and 1 other location - About 6 hrs to fix
          _frontend/dev/js/vendor/fastclick.js on lines 315..340

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

          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

          FastClick.prototype.updateScrollParent = function(targetElement) {
              'use strict';
              var scrollParent, parentElement;
          
              scrollParent = targetElement.fastClickScrollParent;
          Severity: Major
          Found in _frontend/dev/js/vendor/fastclick.js and 1 other location - About 6 hrs to fix
          _frontend/assets/js/vendor/fastclick.min.js on lines 315..340

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

          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 getResults has 154 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                              getResults: function(w, S) {
                                  var O, L, J, u, t, H, T, G, F, x, v, r, W, Q, I, s, E, D, y, A, N, K, B, z = / <button [\s\S]+<\/button>/,
                                      q = YSLOW.util,
                                      C = q.isArray,
                                      V = {},
          Severity: Major
          Found in performance/yslow.js - About 6 hrs to fix
            Severity
            Category
            Status
            Source
            Language