brandon14/ebay-sdk-php

View on GitHub

Showing 3,709 of 3,709 total issues

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

    public function enableInventoryLocationRequest($merchant_location_key)
    {
        // Verify the required parameter 'merchant_location_key' is set.
        if ($merchant_location_key === null || (\is_array($merchant_location_key) && count($merchant_location_key) === 0)) {
            throw new \InvalidArgumentException('Missing the required parameter $merchant_location_key when calling enableInventoryLocation');
Severity: Major
Found in src/Sell/Account/V1/Api/LocationApi.php and 3 other locations - About 3 days to fix
src/Sell/Account/V1/Api/CountryApi.php on lines 328..422
src/Sell/Account/V1/Api/LocationApi.php on lines 793..887
src/Sell/Account/V1/Api/LocationApi.php on lines 1337..1431

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

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

    public function getInventoryLocationRequest($merchant_location_key)
    {
        // Verify the required parameter 'merchant_location_key' is set.
        if ($merchant_location_key === null || (\is_array($merchant_location_key) && count($merchant_location_key) === 0)) {
            throw new \InvalidArgumentException('Missing the required parameter $merchant_location_key when calling getInventoryLocation');
Severity: Major
Found in src/Sell/Account/V1/Api/LocationApi.php and 3 other locations - About 3 days to fix
src/Sell/Account/V1/Api/CountryApi.php on lines 328..422
src/Sell/Account/V1/Api/LocationApi.php on lines 793..887
src/Sell/Account/V1/Api/LocationApi.php on lines 1065..1159

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

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

    public function getSalesTaxJurisdictionsRequest($country_code)
    {
        // Verify the required parameter 'country_code' is set.
        if ($country_code === null || (\is_array($country_code) && count($country_code) === 0)) {
            throw new \InvalidArgumentException('Missing the required parameter $country_code when calling getSalesTaxJurisdictions');
Severity: Major
Found in src/Sell/Account/V1/Api/CountryApi.php and 3 other locations - About 3 days to fix
src/Sell/Account/V1/Api/LocationApi.php on lines 793..887
src/Sell/Account/V1/Api/LocationApi.php on lines 1065..1159
src/Sell/Account/V1/Api/LocationApi.php on lines 1337..1431

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

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

File SubscriptionApi.php has 1185 lines of code (exceeds 250 allowed). Consider refactoring.
Open

<?php

/**
 * This file is part of the trollandtoad/ebay-sdk-php package.
 *
Severity: Major
Found in src/Commerce/Notification/V1/Api/SubscriptionApi.php - About 3 days to fix

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

        public function getReportTasksRequest($limit = null, $offset = null, $report_task_statuses = null)
        {
            $resourcePath = '/ad_report_task';
            $formParams = [];
            $queryParams = [];
    Severity: Major
    Found in src/Sell/Marketing/V1/Api/AdReportTaskApi.php and 1 other location - About 3 days to fix
    src/Sell/Marketing/V1/Api/CampaignApi.php on lines 1241..1339

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

    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 findCampaignByAdReferenceRequest($inventory_reference_id = null, $inventory_reference_type = null, $listing_id = null)
        {
            $resourcePath = '/ad_campaign/find_campaign_by_ad_reference';
            $formParams = [];
            $queryParams = [];
    Severity: Major
    Found in src/Sell/Marketing/V1/Api/CampaignApi.php and 1 other location - About 3 days to fix
    src/Sell/Marketing/V1/Api/AdReportTaskApi.php on lines 976..1074

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

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

        public function getAdsWithHttpInfo($campaign_id, $ad_group_ids = null, $ad_status = null, $limit = null, $listing_ids = null, $offset = null)
        {
            $request = $this->getAdsRequest($campaign_id, $ad_group_ids, $ad_status, $limit, $listing_ids, $offset);
    
            try {
    Severity: Major
    Found in src/Sell/Marketing/V1/Api/AdApi.php and 4 other locations - About 3 days to fix
    src/Buy/Deal/V1/Api/DealItemApi.php on lines 189..254
    src/Sell/Compliance/V1/Api/ListingViolationApi.php on lines 189..254
    src/Sell/Marketing/V1/Api/PromotionApi.php on lines 189..254
    src/Sell/Marketing/V1/Api/PromotionReportApi.php on lines 189..254

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

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

        public function getPromotionReportsWithHttpInfo($marketplace_id, $limit = null, $offset = null, $promotion_status = null, $promotion_type = null, $q = null)
        {
            $request = $this->getPromotionReportsRequest($marketplace_id, $limit, $offset, $promotion_status, $promotion_type, $q);
    
            try {
    Severity: Major
    Found in src/Sell/Marketing/V1/Api/PromotionReportApi.php and 4 other locations - About 3 days to fix
    src/Buy/Deal/V1/Api/DealItemApi.php on lines 189..254
    src/Sell/Compliance/V1/Api/ListingViolationApi.php on lines 189..254
    src/Sell/Marketing/V1/Api/AdApi.php on lines 3591..3656
    src/Sell/Marketing/V1/Api/PromotionApi.php on lines 189..254

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

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

        public function getListingSetWithHttpInfo($promotion_id, $limit = null, $offset = null, $q = null, $sort = null, $status = null)
        {
            $request = $this->getListingSetRequest($promotion_id, $limit, $offset, $q, $sort, $status);
    
            try {
    Severity: Major
    Found in src/Sell/Marketing/V1/Api/PromotionApi.php and 4 other locations - About 3 days to fix
    src/Buy/Deal/V1/Api/DealItemApi.php on lines 189..254
    src/Sell/Compliance/V1/Api/ListingViolationApi.php on lines 189..254
    src/Sell/Marketing/V1/Api/AdApi.php on lines 3591..3656
    src/Sell/Marketing/V1/Api/PromotionReportApi.php on lines 189..254

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

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

        public function getListingViolationsWithHttpInfo($x_ebay_c_marketplace_id, $compliance_type = null, $offset = null, $listing_id = null, $limit = null, $filter = null)
        {
            $request = $this->getListingViolationsRequest($x_ebay_c_marketplace_id, $compliance_type, $offset, $listing_id, $limit, $filter);
    
            try {
    Severity: Major
    Found in src/Sell/Compliance/V1/Api/ListingViolationApi.php and 4 other locations - About 3 days to fix
    src/Buy/Deal/V1/Api/DealItemApi.php on lines 189..254
    src/Sell/Marketing/V1/Api/AdApi.php on lines 3591..3656
    src/Sell/Marketing/V1/Api/PromotionApi.php on lines 189..254
    src/Sell/Marketing/V1/Api/PromotionReportApi.php on lines 189..254

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

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

        public function getDealItemsWithHttpInfo($x_ebay_c_marketplace_id, $category_ids = null, $commissionable = null, $delivery_country = null, $limit = null, $offset = null)
        {
            $request = $this->getDealItemsRequest($x_ebay_c_marketplace_id, $category_ids, $commissionable, $delivery_country, $limit, $offset);
    
            try {
    Severity: Major
    Found in src/Buy/Deal/V1/Api/DealItemApi.php and 4 other locations - About 3 days to fix
    src/Sell/Compliance/V1/Api/ListingViolationApi.php on lines 189..254
    src/Sell/Marketing/V1/Api/AdApi.php on lines 3591..3656
    src/Sell/Marketing/V1/Api/PromotionApi.php on lines 189..254
    src/Sell/Marketing/V1/Api/PromotionReportApi.php on lines 189..254

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

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

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

        public function updateInventoryLocationRequest($merchant_location_key, $inventory_location)
        {
            // Verify the required parameter 'merchant_location_key' is set.
            if ($merchant_location_key === null || (\is_array($merchant_location_key) && count($merchant_location_key) === 0)) {
                throw new \InvalidArgumentException('Missing the required parameter $merchant_location_key when calling updateInventoryLocation');
    Severity: Major
    Found in src/Sell/Inventory/V1/Api/LocationApi.php and 2 other locations - About 3 days to fix
    src/Sell/Feed/V1/Api/ScheduleApi.php on lines 1995..2088
    src/Sell/Inventory/V1/Api/LocationApi.php on lines 271..364

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

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

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

        public function updateScheduleRequest($schedule_id, $update_user_schedule_request)
        {
            // Verify the required parameter 'schedule_id' is set.
            if ($schedule_id === null || (\is_array($schedule_id) && count($schedule_id) === 0)) {
                throw new \InvalidArgumentException('Missing the required parameter $schedule_id when calling updateSchedule');
    Severity: Major
    Found in src/Sell/Feed/V1/Api/ScheduleApi.php and 2 other locations - About 3 days to fix
    src/Sell/Inventory/V1/Api/LocationApi.php on lines 271..364
    src/Sell/Inventory/V1/Api/LocationApi.php on lines 1676..1769

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

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

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

        public function createInventoryLocationRequest($merchant_location_key, $inventory_location_full)
        {
            // Verify the required parameter 'merchant_location_key' is set.
            if ($merchant_location_key === null || (\is_array($merchant_location_key) && count($merchant_location_key) === 0)) {
                throw new \InvalidArgumentException('Missing the required parameter $merchant_location_key when calling createInventoryLocation');
    Severity: Major
    Found in src/Sell/Inventory/V1/Api/LocationApi.php and 2 other locations - About 3 days to fix
    src/Sell/Feed/V1/Api/ScheduleApi.php on lines 1995..2088
    src/Sell/Inventory/V1/Api/LocationApi.php on lines 1676..1769

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

    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 getEventsRequest($x_ebay_c_marketplace_id, $limit = null, $offset = null)
        {
            // Verify the required parameter 'x_ebay_c_marketplace_id' is set.
            if ($x_ebay_c_marketplace_id === null || (\is_array($x_ebay_c_marketplace_id) && count($x_ebay_c_marketplace_id) === 0)) {
                throw new \InvalidArgumentException('Missing the required parameter $x_ebay_c_marketplace_id when calling getEvents');
    Severity: Major
    Found in src/Buy/Deal/V1/Api/EventApi.php and 1 other location - About 3 days to fix
    src/Sell/Negotiation/V1/Api/OfferApi.php on lines 323..419

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

    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 findEligibleItemsRequest($x_ebay_c_marketplace_id, $limit = null, $offset = null)
        {
            // Verify the required parameter 'x_ebay_c_marketplace_id' is set.
            if ($x_ebay_c_marketplace_id === null || (\is_array($x_ebay_c_marketplace_id) && count($x_ebay_c_marketplace_id) === 0)) {
                throw new \InvalidArgumentException('Missing the required parameter $x_ebay_c_marketplace_id when calling findEligibleItems');
    Severity: Major
    Found in src/Sell/Negotiation/V1/Api/OfferApi.php and 1 other location - About 3 days to fix
    src/Buy/Deal/V1/Api/EventApi.php on lines 583..679

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

    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

    CoreItem has 152 functions (exceeds 20 allowed). Consider refactoring.
    Open

    class CoreItem implements ModelInterface, \ArrayAccess, \JsonSerializable
    {
        public const DISCRIMINATOR = null;
    
        /**
    Severity: Major
    Found in src/Buy/Browse/V1/Model/CoreItem.php - About 3 days to fix

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

          public function getCategorySubtreeRequest($category_id, $category_tree_id)
          {
              // Verify the required parameter 'category_id' is set.
              if ($category_id === null || (\is_array($category_id) && count($category_id) === 0)) {
                  throw new \InvalidArgumentException('Missing the required parameter $category_id when calling getCategorySubtree');
      Severity: Major
      Found in src/Commerce/Taxonomy/V1/Api/CategoryTreeApi.php and 3 other locations - About 3 days to fix
      src/Commerce/Taxonomy/V1/Api/CategoryTreeApi.php on lines 852..948
      src/Commerce/Taxonomy/V1/Api/CategoryTreeApi.php on lines 1378..1474
      src/Commerce/Taxonomy/V1/Api/CategoryTreeApi.php on lines 2208..2304

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

      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 createShippingQuoteRequest($x_ebay_c_marketplace_id, $shipping_quote_request)
          {
              // Verify the required parameter 'x_ebay_c_marketplace_id' is set.
              if ($x_ebay_c_marketplace_id === null || (\is_array($x_ebay_c_marketplace_id) && count($x_ebay_c_marketplace_id) === 0)) {
                  throw new \InvalidArgumentException('Missing the required parameter $x_ebay_c_marketplace_id when calling createShippingQuote');
      Severity: Major
      Found in src/Sell/Logistics/V1/Api/ShippingQuoteApi.php and 1 other location - About 3 days to fix
      src/Sell/Inventory/V1/Api/OfferApi.php on lines 804..893

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

      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

          public function getCategorySuggestionsRequest($category_tree_id, $q)
          {
              // Verify the required parameter 'category_tree_id' is set.
              if ($category_tree_id === null || (\is_array($category_tree_id) && count($category_tree_id) === 0)) {
                  throw new \InvalidArgumentException('Missing the required parameter $category_tree_id when calling getCategorySuggestions');
      Severity: Major
      Found in src/Commerce/Taxonomy/V1/Api/CategoryTreeApi.php and 3 other locations - About 3 days to fix
      src/Commerce/Taxonomy/V1/Api/CategoryTreeApi.php on lines 580..676
      src/Commerce/Taxonomy/V1/Api/CategoryTreeApi.php on lines 1378..1474
      src/Commerce/Taxonomy/V1/Api/CategoryTreeApi.php on lines 2208..2304

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

      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