xoopscube/altsys

View on GitHub
xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php

Summary

Maintainability
F
1 wk
Test Coverage

File MyBlocksAdmin.class.php has 821 lines of code (exceeds 250 allowed). Consider refactoring.
Open

<?php
// $Id: MyBlocksAdmin.class.php ,ver 0.0.7.1 2011/02/15 02:55:00 domifara Exp $

class MyBlocksAdmin
{
Severity: Major
Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 day to fix

    MyBlocksAdmin has 32 functions (exceeds 20 allowed). Consider refactoring.
    Open

    class MyBlocksAdmin
    {
    
        public $db ;
        public $lang ;
    Severity: Minor
    Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 4 hrs to fix

      Method form_edit has 99 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          public function form_edit($bid, $mode = 'edit')
          {
              $bid = intval($bid) ;
      
      //HACK by domifara
      Severity: Major
      Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 3 hrs to fix

        Function update_block has a Cognitive Complexity of 27 (exceeds 5 allowed). Consider refactoring.
        Open

            public function update_block($bid, $bside, $bweight, $bvisible, $btitle, $bcontent, $bctype, $bcachetime, $options=array())
            {
                global $xoopsConfig;
        
        //HACK by domifara
        Severity: Minor
        Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 3 hrs to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Method renderCell4BlockPosition has 66 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        public function renderCell4BlockPosition($block_data)
        {
            $bid = intval($block_data['bid']) ;
            $side = intval($block_data['side']) ;
            $visible = intval($block_data['visible']) ;
        Severity: Major
        Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 2 hrs to fix

          Method list_blocks has 53 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          public function list_blocks()
          {
              global $xoopsGTicket ;
          
              // main query
          Severity: Major
          Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 2 hrs to fix

            Method update_block has 50 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                public function update_block($bid, $bside, $bweight, $bvisible, $btitle, $bcontent, $bctype, $bcachetime, $options=array())
                {
                    global $xoopsConfig;
            
            //HACK by domifara
            Severity: Minor
            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 2 hrs to fix

              Function canClone has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
              Open

              public function canClone($block)
              {
                  // can clone link if it is marked as cloneable block
                  if ($block->getVar("block_type") == 'D' || $block->getVar("block_type") == 'C') {
                      return 2 ;
              Severity: Minor
              Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

              Cognitive Complexity

              Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

              A method's cognitive complexity is based on a few simple rules:

              • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
              • Code is considered more complex for each "break in the linear flow of the code"
              • Code is considered more complex when "flow breaking structures are nested"

              Further reading

              Method do_clone has 42 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  public function do_clone($bid)
                  {
                      $bid = intval($bid) ;
              
                      $request = $this->fetchRequest4Block($bid) ;
              Severity: Minor
              Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

                Function form_edit has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring.
                Open

                    public function form_edit($bid, $mode = 'edit')
                    {
                        $bid = intval($bid) ;
                
                //HACK by domifara
                Severity: Minor
                Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

                Cognitive Complexity

                Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                A method's cognitive complexity is based on a few simple rules:

                • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                • Code is considered more complex for each "break in the linear flow of the code"
                • Code is considered more complex when "flow breaking structures are nested"

                Further reading

                Method init has 33 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    public function init($xoopsModule)
                    {
                        // altsys "module" MODE
                    if ($xoopsModule->getVar('dirname') == 'altsys') {
                        // set target_module if specified by $_GET['dirname']
                Severity: Minor
                Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

                  Method renderCell4BlockModuleLink has 32 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                  public function renderCell4BlockModuleLink($block_data)
                  {
                      $bid = intval($block_data['bid']) ;
                  
                      // get selected targets
                  Severity: Minor
                  Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

                    Function renderCell4BlockReadGroupPerm has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
                    Open

                    public function renderCell4BlockReadGroupPerm($block_data)
                    {
                        $bid = intval($block_data['bid']) ;
                    
                        // get selected targets
                    Severity: Minor
                    Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

                    Cognitive Complexity

                    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                    A method's cognitive complexity is based on a few simple rules:

                    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                    • Code is considered more complex for each "break in the linear flow of the code"
                    • Code is considered more complex when "flow breaking structures are nested"

                    Further reading

                    Function do_clone has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
                    Open

                        public function do_clone($bid)
                        {
                            $bid = intval($bid) ;
                    
                            $request = $this->fetchRequest4Block($bid) ;
                    Severity: Minor
                    Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

                    Cognitive Complexity

                    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                    A method's cognitive complexity is based on a few simple rules:

                    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                    • Code is considered more complex for each "break in the linear flow of the code"
                    • Code is considered more complex when "flow breaking structures are nested"

                    Further reading

                    Method renderCell4BlockReadGroupPerm has 30 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                    public function renderCell4BlockReadGroupPerm($block_data)
                    {
                        $bid = intval($block_data['bid']) ;
                    
                        // get selected targets
                    Severity: Minor
                    Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

                      Method update_block has 9 arguments (exceeds 4 allowed). Consider refactoring.
                      Open

                          public function update_block($bid, $bside, $bweight, $bvisible, $btitle, $bcontent, $bctype, $bcachetime, $options=array())
                      Severity: Major
                      Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

                        Method construct has 28 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            public function construct()
                            {
                                $this->db =& XoopsDatabaseFactory::getDatabaseConnection() ;
                                $this->lang = @$GLOBALS['xoopsConfig']['language'] ;
                        
                        
                        Severity: Minor
                        Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

                          Method list_groups has 28 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                              public function list_groups()
                              {
                                  // query for getting blocks
                              $sql = "SELECT * FROM ".$this->db->prefix("newblocks")." WHERE mid='$this->target_mid' ORDER BY visible DESC,side,weight" ;
                                  $result = $this->db->query($sql) ;
                          Severity: Minor
                          Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

                            Function renderCell4BlockModuleLink has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
                            Open

                            public function renderCell4BlockModuleLink($block_data)
                            {
                                $bid = intval($block_data['bid']) ;
                            
                                // get selected targets
                            Severity: Minor
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 1 hr to fix

                            Cognitive Complexity

                            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                            A method's cognitive complexity is based on a few simple rules:

                            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                            • Code is considered more complex for each "break in the linear flow of the code"
                            • Code is considered more complex when "flow breaking structures are nested"

                            Further reading

                            Function renderCell4BlockPosition has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                            Open

                            public function renderCell4BlockPosition($block_data)
                            {
                                $bid = intval($block_data['bid']) ;
                                $side = intval($block_data['side']) ;
                                $visible = intval($block_data['visible']) ;
                            Severity: Minor
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 55 mins to fix

                            Cognitive Complexity

                            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                            A method's cognitive complexity is based on a few simple rules:

                            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                            • Code is considered more complex for each "break in the linear flow of the code"
                            • Code is considered more complex when "flow breaking structures are nested"

                            Further reading

                            Function processPost has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                            Open

                                public function processPost()
                                {
                                    // Ticket Check
                                if (! $GLOBALS['xoopsGTicket']->check(true, 'myblocksadmin')) {
                                    redirect_header(XOOPS_URL.'/', 3, $GLOBALS['xoopsGTicket']->getErrors());
                            Severity: Minor
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 45 mins to fix

                            Cognitive Complexity

                            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                            A method's cognitive complexity is based on a few simple rules:

                            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                            • Code is considered more complex for each "break in the linear flow of the code"
                            • Code is considered more complex when "flow breaking structures are nested"

                            Further reading

                            Function list_groups has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                            Open

                                public function list_groups()
                                {
                                    // query for getting blocks
                                $sql = "SELECT * FROM ".$this->db->prefix("newblocks")." WHERE mid='$this->target_mid' ORDER BY visible DESC,side,weight" ;
                                    $result = $this->db->query($sql) ;
                            Severity: Minor
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 45 mins to fix

                            Cognitive Complexity

                            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                            A method's cognitive complexity is based on a few simple rules:

                            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                            • Code is considered more complex for each "break in the linear flow of the code"
                            • Code is considered more complex when "flow breaking structures are nested"

                            Further reading

                            Function init has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                            Open

                                public function init($xoopsModule)
                                {
                                    // altsys "module" MODE
                                if ($xoopsModule->getVar('dirname') == 'altsys') {
                                    // set target_module if specified by $_GET['dirname']
                            Severity: Minor
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 35 mins to fix

                            Cognitive Complexity

                            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                            A method's cognitive complexity is based on a few simple rules:

                            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                            • Code is considered more complex for each "break in the linear flow of the code"
                            • Code is considered more complex when "flow breaking structures are nested"

                            Further reading

                            Function list_blocks has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                            Open

                            public function list_blocks()
                            {
                                global $xoopsGTicket ;
                            
                                // main query
                            Severity: Minor
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 35 mins to fix

                            Cognitive Complexity

                            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                            A method's cognitive complexity is based on a few simple rules:

                            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                            • Code is considered more complex for each "break in the linear flow of the code"
                            • Code is considered more complex when "flow breaking structures are nested"

                            Further reading

                            Function do_edit has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                            Open

                                public function do_edit($bid)
                                {
                                    $bid = intval($bid) ;
                            
                                    if ($bid <= 0) {
                            Severity: Minor
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php - About 35 mins to fix

                            Cognitive Complexity

                            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                            A method's cognitive complexity is based on a few simple rules:

                            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                            • Code is considered more complex for each "break in the linear flow of the code"
                            • Code is considered more complex when "flow breaking structures are nested"

                            Further reading

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

                                return "
                                            <div class='blockposition $scol0'>
                                                <input type='radio' name='sides[$bid]' value='".XOOPS_SIDEBLOCK_LEFT."' class='blockposition' $ssel0 onclick='document.getElementById(\"extra_side_$bid\").value=".XOOPS_SIDEBLOCK_LEFT.";' />
                                            </div>
                                            <div style='float:"._GLOBAL_LEFT.";'>-</div>
                            Severity: Major
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php and 1 other location - About 5 hrs to fix
                            xoops_trust_path/libs/altsys/class/MyBlocksAdminForX25.class.php on lines 89..123

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

                            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

                                $block_data = $this->preview_request + array(
                                    'bid' => $bid ,
                                    'name' => $block->getVar('name', 'n') ,
                                    'title' => $block->getVar('title', 'n') ,
                                    'weight' => intval($block->getVar('weight')) ,
                            Severity: Major
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php and 1 other location - About 4 hrs to fix
                            xoops_trust_path/libs/altsys/class/MyBlocksAdminForX25.class.php on lines 212..227

                            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

                                    switch ($mode) {
                                    case 'clone' :
                                        $form_title = _MD_A_MYBLOCKSADMIN_CLONEFORM ;
                                        $button_value = _MD_A_MYBLOCKSADMIN_BTN_CLONE ;
                                        $next_op = 'clone_ok' ;
                            Severity: Major
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php and 1 other location - About 4 hrs to fix
                            xoops_trust_path/libs/altsys/class/MyBlocksAdminForX25.class.php on lines 168..194

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

                            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 (! $is_custom && $block_template) {
                                        // find template of the block
                                    $tplfile_handler =& xoops_gethandler('tplfile');
                                        $found_templates = $tplfile_handler->find($GLOBALS['xoopsConfig']['template_set'], 'block', null, null, $block_template) ;
                                        $block_template_tplset = count($found_templates) > 0 ? $GLOBALS['xoopsConfig']['template_set'] : 'default' ;
                            Severity: Minor
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php and 1 other location - About 45 mins to fix
                            xoops_trust_path/libs/altsys/class/MyBlocksAdminForX25.class.php on lines 200..205

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

                            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

                                    $block4assign = array(
                                    'name_raw' => $block_data['name'] ,
                                    'title_raw' => $block_data['title'] ,
                                    'content_raw' => $block_data['content'] ,
                                    'cell_position' => $this->renderCell4BlockPosition($block_data) ,
                            Severity: Minor
                            Found in xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php and 1 other location - About 40 mins to fix
                            xoops_trust_path/libs/altsys/class/MyBlocksAdminForX25.class.php on lines 229..238

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

                            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

                            There are no issues that match your filters.

                            Category
                            Status