warlof/seat-migrator

View on GitHub

Showing 52 of 52 total issues

File alliances.php has 545 lines of code (exceeds 250 allowed). Consider refactoring.
Open

<?php

return [
    101677770,
    117383987,
Severity: Major
Found in src/Config/alliances.php - About 1 day to fix

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

    <?php
    /**
     * Created by PhpStorm.
     * User: Warlof Tutsimo
     * Date: 22/04/2018
    Severity: Major
    Found in src/Models/CorporationIndustryJob.php and 1 other location - About 1 day to fix
    src/Models/CharacterIndustryJob.php on lines 1..71

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

    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
    /**
     * Created by PhpStorm.
     * User: Warlof Tutsimo
     * Date: 26/04/2018
    Severity: Major
    Found in src/Models/CharacterAssetList.php and 1 other location - About 1 day to fix
    src/Models/CorporationAssetListContent.php on lines 1..67

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

    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
    /**
     * Created by PhpStorm.
     * User: Warlof Tutsimo
     * Date: 20/04/2018
    Severity: Major
    Found in src/Models/CharacterIndustryJob.php and 1 other location - About 1 day to fix
    src/Models/CorporationIndustryJob.php on lines 1..71

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

    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
    /**
     * Created by PhpStorm.
     * User: Warlof Tutsimo
     * Date: 26/04/2018
    Severity: Major
    Found in src/Models/CorporationAssetListContent.php and 1 other location - About 1 day to fix
    src/Models/CharacterAssetList.php on lines 1..67

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

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

        public function handle()
        {
            $this->promptSetup();
            $this->backups();
    
    
    Severity: Major
    Found in src/Commands/Upgrade.php - About 3 hrs to fix

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

          public function getUpgradeMapping(): array
          {
              return [
                  'contract_details' => [
                      'contractID'     => 'contract_id',
      Severity: Major
      Found in src/Models/CorporationContract.php and 1 other location - About 3 hrs to fix
      src/Models/CharacterContract.php on lines 69..105

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

      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 getUpgradeMapping(): array
          {
              return [
                  'contract_details' => [
                      'contractID'      => 'contract_id',
      Severity: Major
      Found in src/Models/CharacterContract.php and 1 other location - About 3 hrs to fix
      src/Models/CorporationContract.php on lines 18..54

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

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

          public function getUpgradeMapping(): array
          {
              return [
                  'character_infos'       => [
                      'characterID'    => 'character_id',
      Severity: Major
      Found in src/Models/CharacterSheet.php - About 2 hrs to fix

        Method upgrade has 49 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            public function upgrade(string $target)
            {
                if (self::$alliance_ids == [])
                    self::$alliance_ids = include __DIR__ . '/../Config/alliances.php';
        
        
        Severity: Minor
        Found in src/Models/MailHeader.php - About 1 hr to fix

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

              public function getUpgradeMapping(): array
              {
                  return [
                      'character_planet_pins' => [
                          'ownerID'        => 'character_id',
          Severity: Minor
          Found in src/Models/CharacterPlanetPin.php - About 1 hr to fix

            Method getUpgradeMapping has 35 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                public function getUpgradeMapping(): array
                {
                    return [
                        'character_killmails' => [
                            'characterID' => 'character_id',
            Severity: Minor
            Found in src/Models/Killmail.php - About 1 hr to fix

              Method getUpgradeMapping has 35 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  public function getUpgradeMapping(): array
                  {
                      return [
                          'corporation_member_trackings' => [
                              'corporationID'  => 'corporation_id',
              Severity: Minor
              Found in src/Models/CorporationMemberTracking.php - About 1 hr to fix

                Method getUpgradeMapping has 34 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    public function getUpgradeMapping(): array
                    {
                        return [
                            'contract_details' => [
                                'contractID'      => 'contract_id',
                Severity: Minor
                Found in src/Models/CharacterContract.php - About 1 hr to fix

                  Method getUpgradeMapping has 34 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      public function getUpgradeMapping(): array
                      {
                          return [
                              'contract_details' => [
                                  'contractID'     => 'contract_id',
                  Severity: Minor
                  Found in src/Models/CorporationContract.php - About 1 hr to fix

                    Method getUpgradeMapping has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        public function getUpgradeMapping(): array
                        {
                            return [
                                'character_calendar_event_details' => [
                                    'eventID'     => 'event_id',
                    Severity: Minor
                    Found in src/Models/CharacterCalendarEventDetail.php - About 1 hr to fix

                      Method getUpgradeMapping has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          public function getUpgradeMapping(): array
                          {
                              return [
                                  'corporation_industry_jobs' => [
                                      'corporationID'        => 'corporation_id',
                      Severity: Minor
                      Found in src/Models/CorporationIndustryJob.php - About 1 hr to fix

                        Method getUpgradeMapping has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            public function getUpgradeMapping(): array
                            {
                                return [
                                    'corporation_bookmarks' => [
                                        'corporationID' => 'corporation_id',
                        Severity: Minor
                        Found in src/Models/CorporationBookmark.php - About 1 hr to fix

                          Method getUpgradeMapping has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                              public function getUpgradeMapping(): array
                              {
                                  return [
                                      'character_industry_jobs' => [
                                          'characterID'          => 'character_id',
                          Severity: Minor
                          Found in src/Models/CharacterIndustryJob.php - About 1 hr to fix

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

                                public function getUpgradeMapping() : array
                                {
                                    return [
                                        'character_bookmarks' => [
                                            'characterID' => 'character_id',
                            Severity: Minor
                            Found in src/Models/CharacterBookmark.php - About 1 hr to fix
                              Severity
                              Category
                              Status
                              Source
                              Language