CaffGeek/MBACNationals

View on GitHub

Showing 7,504 of 7,504 total issues

Method the_editor has 47 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function the_editor($content, $id = 'content', $prev_id = 'title', $media_buttons = true, $tab_index = 2) {
    $rows = get_option('default_post_edit_rows');
    if (($rows < 3) || ($rows > 100))
        $rows = 12;

Severity: Minor
Found in Web.Admin/2014/wordpress/wp-includes/general-template.php - About 1 hr to fix

    Method wp_delete_term has 47 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function wp_delete_term( $term, $taxonomy, $args = array() ) {
        global $wpdb;
    
        $term = (int) $term;
    
    
    Severity: Minor
    Found in Web.Admin/2014/wordpress/wp-includes/taxonomy.php - About 1 hr to fix

      Method render_content has 47 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          public function render_content() {
              $this->print_header_image_template();
              $visibility = $this->get_current_image_src() ? '' : ' style="display:none" ';
              $width = absint( get_theme_support( 'custom-header', 'width' ) );
              $height = absint( get_theme_support( 'custom-header', 'height' ) );
      Severity: Minor
      Found in Web.Admin/2014/wordpress/wp-includes/class-wp-customize-control.php - About 1 hr to fix

        Method wp_dropdown_categories has 47 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function wp_dropdown_categories( $args = '' ) {
            $defaults = array(
                'show_option_all' => '', 'show_option_none' => '',
                'orderby' => 'id', 'order' => 'ASC',
                'show_last_update' => 0, 'show_count' => 0,
        Severity: Minor
        Found in Web.Admin/2014/wordpress/wp-includes/category-template.php - About 1 hr to fix

          Method wp_dropdown_users has 47 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          function wp_dropdown_users( $args = '' ) {
              global $wpdb;
              $defaults = array(
                  'show_option_all' => '', 'show_option_none' => '',
                  'orderby' => 'display_name', 'order' => 'ASC',
          Severity: Minor
          Found in Web.Admin/2014/wordpress/wp-includes/user.php - About 1 hr to fix

            Method wp_load_translations_early has 47 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            function wp_load_translations_early() {
                global $text_direction, $wp_locale;
            
                static $loaded = false;
                if ( $loaded )
            Severity: Minor
            Found in Web.Admin/2014/wordpress/wp-includes/load.php - About 1 hr to fix

              Method Handle has 47 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                      public void Handle(TeamGameCompleted e)
                      {
                          var teamId = e.TeamId;
              
                          //HACK: Old TeamGameCompleted events used teamid instead of bowlerid for POA singles 8'(
              Severity: Minor
              Found in ReadModels/TeamScoreQueries.cs - About 1 hr to fix

                Method Handle has 47 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                        public void Handle(ParticipantGameCompleted e)
                        {
                            var participant = Participants.Single(x => x.Id == e.ParticipantId);
                            var game = participant.Scores.SingleOrDefault(x => x.MatchId == e.Id);
                
                
                Severity: Minor
                Found in ReadModels/ParticipantScoreQueries.cs - About 1 hr to fix

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

                              if (agg.Name != command.Name)
                              {
                                  yield return new ParticipantRenamed
                                  {
                                      Id = command.Id,
                  Severity: Major
                  Found in Aggregates/Participant/ParticipantCommandHandlers.cs and 1 other location - About 1 hr to fix
                  Aggregates/Participant/ParticipantCommandHandlers.cs on lines 230..240

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

                  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 (agg.Name != command.Name)
                              {
                                  yield return new ParticipantRenamed
                                  {
                                      Id = command.Id,
                  Severity: Major
                  Found in Aggregates/Participant/ParticipantCommandHandlers.cs and 1 other location - About 1 hr to fix
                  Aggregates/Participant/ParticipantCommandHandlers.cs on lines 89..99

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

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

                          elseif (substr($data, 0, 10) === "\x00\x3C\x00\x3F\x00\x78\x00\x6D\x00\x6C")
                          {
                              if ($pos = strpos($data, "\x00\x3F\x00\x3E"))
                              {
                                  $parser = $registry->create('XML_Declaration_Parser', array(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 10), 'UTF-16BE', 'UTF-8')));
                  Severity: Major
                  Found in Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php and 3 other locations - About 1 hr to fix
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2052..2063
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2065..2076
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2091..2102

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

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

                          elseif (substr($data, 0, 20) === "\x00\x00\x00\x3C\x00\x00\x00\x3F\x00\x00\x00\x78\x00\x00\x00\x6D\x00\x00\x00\x6C")
                          {
                              if ($pos = strpos($data, "\x00\x00\x00\x3F\x00\x00\x00\x3E"))
                              {
                                  $parser = $registry->create('XML_Declaration_Parser', array(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 20), 'UTF-32BE', 'UTF-8')));
                  Severity: Major
                  Found in Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php and 3 other locations - About 1 hr to fix
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2065..2076
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2078..2089
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2091..2102

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

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

                          elseif (substr($data, 0, 20) === "\x3C\x00\x00\x00\x3F\x00\x00\x00\x78\x00\x00\x00\x6D\x00\x00\x00\x6C\x00\x00\x00")
                          {
                              if ($pos = strpos($data, "\x3F\x00\x00\x00\x3E\x00\x00\x00"))
                              {
                                  $parser = $registry->create('XML_Declaration_Parser', array(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 20), 'UTF-32LE', 'UTF-8')));
                  Severity: Major
                  Found in Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php and 3 other locations - About 1 hr to fix
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2052..2063
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2078..2089
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2091..2102

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

                  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

                      function get_category_permastruct() {
                          if (isset($this->category_structure)) {
                              return $this->category_structure;
                          }
                  
                  
                  Severity: Major
                  Found in Web.Admin/2014/wordpress/wp-includes/rewrite.php and 1 other location - About 1 hr to fix
                  Web.Admin/2014/wordpress/wp-includes/rewrite.php on lines 1033..1051

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

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

                          elseif (substr($data, 0, 10) === "\x3C\x00\x3F\x00\x78\x00\x6D\x00\x6C\x00")
                          {
                              if ($pos = strpos($data, "\x3F\x00\x3E\x00"))
                              {
                                  $parser = $registry->create('XML_Declaration_Parser', array(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 10), 'UTF-16LE', 'UTF-8')));
                  Severity: Major
                  Found in Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php and 3 other locations - About 1 hr to fix
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2052..2063
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2065..2076
                  Web.Admin/2014/wordpress/wp-includes/SimplePie/Misc.php on lines 2078..2089

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

                  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

                      function get_tag_permastruct() {
                          if (isset($this->tag_structure)) {
                              return $this->tag_structure;
                          }
                  
                  
                  Severity: Major
                  Found in Web.Admin/2014/wordpress/wp-includes/rewrite.php and 1 other location - About 1 hr to fix
                  Web.Admin/2014/wordpress/wp-includes/rewrite.php on lines 1000..1018

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

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

                  Language.complete = [
                      { input : '\'', output : '\'$0\'' },
                      { input : '"', output : '"$0"' },
                      { input : '(', output : '\($0\)' },
                      { input : '[', output : '\[$0\]' },
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/css.js on lines 15..21
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/html.js on lines 51..57
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/java.js on lines 16..22
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/javascript.js on lines 22..28
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/perl.js on lines 19..25
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/php.js on lines 48..54
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/ruby.js on lines 18..24
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/sql.js on lines 19..25

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

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

                  Language.complete = [
                      { input : '\'',output : '\'$0\'' },
                      { input : '"', output : '"$0"' },
                      { input : '(', output : '\($0\)' },
                      { input : '[', output : '\[$0\]' },
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/generic.js on lines 17..23
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/html.js on lines 51..57
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/java.js on lines 16..22
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/javascript.js on lines 22..28
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/perl.js on lines 19..25
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/php.js on lines 48..54
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/ruby.js on lines 18..24
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/sql.js on lines 19..25

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

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

                  Language.complete = [
                      { input : '\'',output : '\'$0\'' },
                      { input : '"', output : '"$0"' },
                      { input : '(', output : '\($0\)' },
                      { input : '[', output : '\[$0\]' },
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/css.js on lines 15..21
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/generic.js on lines 17..23
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/html.js on lines 51..57
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/java.js on lines 16..22
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/perl.js on lines 19..25
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/php.js on lines 48..54
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/ruby.js on lines 18..24
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/sql.js on lines 19..25

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

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

                  Language.complete = [
                      { input : '\'', output : '\'$0\'' },
                      { input : '"', output : '"$0"' },
                      { input : '(', output : '\($0\)' },
                      { input : '[', output : '\[$0\]' },
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/css.js on lines 15..21
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/generic.js on lines 17..23
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/html.js on lines 51..57
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/java.js on lines 16..22
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/javascript.js on lines 22..28
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/perl.js on lines 19..25
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/ruby.js on lines 18..24
                  Web.Admin/2014/wordpress/wp-includes/js/codepress/languages/sql.js on lines 19..25

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

                  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