vragovR/omnidesk-bundle

View on GitHub

Showing 75 of 75 total issues

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

<?php
namespace OmnideskBundle\Request\User;

use OmnideskBundle\Request\RequestInterface;

Severity: Major
Found in src/Request/User/AddUserRequest.php and 1 other location - About 1 day to fix
src/Request/User/EditUserRequest.php on lines 1..203

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

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

<?php
namespace OmnideskBundle\Request\User;

use OmnideskBundle\Request\RequestInterface;

Severity: Major
Found in src/Request/User/EditUserRequest.php and 1 other location - About 1 day to fix
src/Request/User/AddUserRequest.php on lines 1..203

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

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

Cases has 34 functions (exceeds 20 allowed). Consider refactoring.
Open

class Cases
{
    /**
     * @var string
     */
Severity: Minor
Found in src/Model/Cases.php - About 4 hrs to fix

    User has 30 functions (exceeds 20 allowed). Consider refactoring.
    Open

    class User
    {
        /**
         * @var int
         */
    Severity: Minor
    Found in src/Model/User.php - About 3 hrs to fix

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

      <?php
      namespace OmnideskBundle\Configuration\User;
      
      use Symfony\Component\Config\Definition\Builder\TreeBuilder;
      use Symfony\Component\Config\Definition\ConfigurationInterface;
      Severity: Major
      Found in src/Configuration/User/EditUserRequestConfiguration.php and 1 other location - About 3 hrs to fix
      src/Configuration/User/AddUserRequestConfiguration.php on lines 1..53

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

      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

      <?php
      namespace OmnideskBundle\Configuration\User;
      
      use Symfony\Component\Config\Definition\Builder\TreeBuilder;
      use Symfony\Component\Config\Definition\ConfigurationInterface;
      Severity: Major
      Found in src/Configuration/User/AddUserRequestConfiguration.php and 1 other location - About 3 hrs to fix
      src/Configuration/User/EditUserRequestConfiguration.php on lines 1..53

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

      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

      Method getConfigTreeBuilder has 85 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          public function getConfigTreeBuilder()
          {
              $treeBuilder = new TreeBuilder();
      
              $rootNode = $treeBuilder->root('params');
      Severity: Major
      Found in src/Configuration/Cases/ListCasesRequestConfiguration.php - About 3 hrs to fix

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

        <?php
        namespace OmnideskBundle\Factory\Message;
        
        use OmnideskBundle\DataTransformer\DataTransformerInterface;
        use OmnideskBundle\DataTransformer\Request\Message\AddMessageRequestDataTransformer;
        Severity: Major
        Found in src/Factory/Message/MessageDataTransformerFactory.php and 3 other locations - About 3 hrs to fix
        src/Factory/Cases/CasesConfigurationFactory.php on lines 1..57
        src/Factory/Staff/StaffConfigurationFactory.php on lines 1..57
        src/Factory/User/UserConfigurationFactory.php on lines 1..57

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

        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

        <?php
        namespace OmnideskBundle\Factory\User;
        
        use OmnideskBundle\Configuration\User\AddUserRequestConfiguration;
        use OmnideskBundle\Configuration\User\EditUserRequestConfiguration;
        Severity: Major
        Found in src/Factory/User/UserConfigurationFactory.php and 3 other locations - About 3 hrs to fix
        src/Factory/Cases/CasesConfigurationFactory.php on lines 1..57
        src/Factory/Message/MessageDataTransformerFactory.php on lines 1..57
        src/Factory/Staff/StaffConfigurationFactory.php on lines 1..57

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

        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

        <?php
        namespace OmnideskBundle\Factory\Staff;
        
        use OmnideskBundle\Configuration\Staff\AddStaffRequestConfiguration;
        use OmnideskBundle\Configuration\Staff\EditStaffRequestConfiguration;
        Severity: Major
        Found in src/Factory/Staff/StaffConfigurationFactory.php and 3 other locations - About 3 hrs to fix
        src/Factory/Cases/CasesConfigurationFactory.php on lines 1..57
        src/Factory/Message/MessageDataTransformerFactory.php on lines 1..57
        src/Factory/User/UserConfigurationFactory.php on lines 1..57

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

        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

        <?php
        namespace OmnideskBundle\Factory\Cases;
        
        use OmnideskBundle\Configuration\Cases\AddCasesRequestConfiguration;
        use OmnideskBundle\Configuration\Cases\EditCasesRequestConfiguration;
        Severity: Major
        Found in src/Factory/Cases/CasesConfigurationFactory.php and 3 other locations - About 3 hrs to fix
        src/Factory/Message/MessageDataTransformerFactory.php on lines 1..57
        src/Factory/Staff/StaffConfigurationFactory.php on lines 1..57
        src/Factory/User/UserConfigurationFactory.php on lines 1..57

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

        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

        ListCasesRequest has 28 functions (exceeds 20 allowed). Consider refactoring.
        Open

        class ListCasesRequest implements RequestInterface
        {
            /**
             * @var string
             */
        Severity: Minor
        Found in src/Request/Cases/ListCasesRequest.php - About 3 hrs to fix

          AddCasesRequest has 27 functions (exceeds 20 allowed). Consider refactoring.
          Open

          class AddCasesRequest implements RequestInterface
          {
              /**
               * @var string
               */
          Severity: Minor
          Found in src/Request/Cases/AddCasesRequest.php - About 3 hrs to fix

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

                public function edit(EditGroupRequest $request)
                {
                    $transformer = $this->transformerFactory->get(GroupDataTransformerFactory::REQUEST_EDIT);
                    $configuration = $this->configurationFactory->get(GroupConfigurationFactory::CONFIGURATION_EDIT);
            
            
            Severity: Major
            Found in src/Service/GroupService.php and 1 other location - About 2 hrs to fix
            src/Service/UserService.php on lines 97..111

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

            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

                public function edit(EditUserRequest $request)
                {
                    $transformer = $this->transformerFactory->get(UserDataTransformerFactory::REQUEST_EDIT);
                    $configuration = $this->configurationFactory->get(UserConfigurationFactory::CONFIGURATION_EDIT);
            
            
            Severity: Major
            Found in src/Service/UserService.php and 1 other location - About 2 hrs to fix
            src/Service/GroupService.php on lines 75..89

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

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

                public function disable(ViewStaffRequest $request)
                {
                    $transformer = $this->transformerFactory->get(StaffDataTransformerFactory::REQUEST_VIEW);
                    $configuration = $this->configurationFactory->get(StaffConfigurationFactory::CONFIGURATION_VIEW);
            
            
            Severity: Major
            Found in src/Service/StaffService.php and 9 other locations - About 2 hrs to fix
            src/Service/CasesService.php on lines 151..165
            src/Service/CasesService.php on lines 172..186
            src/Service/CasesService.php on lines 193..207
            src/Service/GroupService.php on lines 135..149
            src/Service/GroupService.php on lines 155..169
            src/Service/StaffService.php on lines 169..183
            src/Service/UserService.php on lines 157..171
            src/Service/UserService.php on lines 177..191
            src/Service/UserService.php on lines 197..211

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

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

                public function spam(ViewCasesRequest $request)
                {
                    $transformer = $this->transformerFactory->get(CasesDataTransformerFactory::REQUEST_VIEW);
                    $configuration = $this->configurationFactory->get(CasesConfigurationFactory::CONFIGURATION_VIEW);
            
            
            Severity: Major
            Found in src/Service/CasesService.php and 9 other locations - About 2 hrs to fix
            src/Service/CasesService.php on lines 151..165
            src/Service/CasesService.php on lines 193..207
            src/Service/GroupService.php on lines 135..149
            src/Service/GroupService.php on lines 155..169
            src/Service/StaffService.php on lines 149..163
            src/Service/StaffService.php on lines 169..183
            src/Service/UserService.php on lines 157..171
            src/Service/UserService.php on lines 177..191
            src/Service/UserService.php on lines 197..211

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

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

                public function restore(ViewCasesRequest $request)
                {
                    $transformer = $this->transformerFactory->get(CasesDataTransformerFactory::REQUEST_VIEW);
                    $configuration = $this->configurationFactory->get(CasesConfigurationFactory::CONFIGURATION_VIEW);
            
            
            Severity: Major
            Found in src/Service/CasesService.php and 9 other locations - About 2 hrs to fix
            src/Service/CasesService.php on lines 151..165
            src/Service/CasesService.php on lines 172..186
            src/Service/GroupService.php on lines 135..149
            src/Service/GroupService.php on lines 155..169
            src/Service/StaffService.php on lines 149..163
            src/Service/StaffService.php on lines 169..183
            src/Service/UserService.php on lines 157..171
            src/Service/UserService.php on lines 177..191
            src/Service/UserService.php on lines 197..211

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

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

                public function disable(ViewUserRequest $request)
                {
                    $transformer = $this->transformerFactory->get(UserDataTransformerFactory::REQUEST_VIEW);
                    $configuration = $this->configurationFactory->get(UserConfigurationFactory::CONFIGURATION_VIEW);
            
            
            Severity: Major
            Found in src/Service/UserService.php and 9 other locations - About 2 hrs to fix
            src/Service/CasesService.php on lines 151..165
            src/Service/CasesService.php on lines 172..186
            src/Service/CasesService.php on lines 193..207
            src/Service/GroupService.php on lines 135..149
            src/Service/GroupService.php on lines 155..169
            src/Service/StaffService.php on lines 149..163
            src/Service/StaffService.php on lines 169..183
            src/Service/UserService.php on lines 157..171
            src/Service/UserService.php on lines 177..191

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

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

                public function block(ViewUserRequest $request)
                {
                    $transformer = $this->transformerFactory->get(UserDataTransformerFactory::REQUEST_VIEW);
                    $configuration = $this->configurationFactory->get(UserConfigurationFactory::CONFIGURATION_VIEW);
            
            
            Severity: Major
            Found in src/Service/UserService.php and 9 other locations - About 2 hrs to fix
            src/Service/CasesService.php on lines 151..165
            src/Service/CasesService.php on lines 172..186
            src/Service/CasesService.php on lines 193..207
            src/Service/GroupService.php on lines 135..149
            src/Service/GroupService.php on lines 155..169
            src/Service/StaffService.php on lines 149..163
            src/Service/StaffService.php on lines 169..183
            src/Service/UserService.php on lines 177..191
            src/Service/UserService.php on lines 197..211

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

            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