brandon14/ebay-sdk-php

View on GitHub

Showing 3,709 of 3,709 total issues

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

    public function getNegativeKeywordsAsync($ad_group_ids = null, $campaign_ids = null, $limit = null, $negative_keyword_status = null, $offset = null)
    {
        return $this->getNegativeKeywordsAsyncWithHttpInfo($ad_group_ids, $campaign_ids, $limit, $negative_keyword_status, $offset)
            ->then(
                function ($response) {
Severity: Major
Found in src/Sell/Marketing/V1/Api/NegativeKeywordApi.php and 5 other locations - About 30 mins to fix
src/Sell/Feed/V1/Api/CustomerServiceMetricTaskApi.php on lines 723..731
src/Sell/Finances/V1/Api/PayoutApi.php on lines 774..782
src/Sell/Finances/V1/Api/TransactionApi.php on lines 518..526
src/Sell/Fulfillment/V1/Api/OrderApi.php on lines 527..535
src/Sell/Inventory/V1/Api/OfferApi.php on lines 1693..1701

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

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

    public function search($aspect_filter = null, $category_ids = null, $epid = null, $fieldgroups = null, $filter = null, $gtin = null, $limit = null, $offset = null, $q = null, $sort = null)
    {
        [$response] = $this->searchWithHttpInfo($aspect_filter, $category_ids, $epid, $fieldgroups, $filter, $gtin, $limit, $offset, $q, $sort);

        return $response;
Severity: Major
Found in src/Buy/MarketplaceInsightsBeta/V1/Api/ItemSalesApi.php and 4 other locations - About 30 mins to fix
src/Buy/MarketplaceInsightsBeta/V1/Api/ItemSalesApi.php on lines 197..262
src/Buy/MarketplaceInsightsBeta/V1/Api/ItemSalesApi.php on lines 282..290
src/Buy/MarketplaceInsightsBeta/V1/Api/ItemSalesApi.php on lines 310..338
src/Buy/MarketplaceInsightsBeta/V1/Api/ItemSalesApi.php on lines 358..508

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

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

    public function searchRequest($aspect_filter = null, $category_ids = null, $epid = null, $fieldgroups = null, $filter = null, $gtin = null, $limit = null, $offset = null, $q = null, $sort = null)
    {
        $resourcePath = '/item_sales/search';
        $formParams = [];
        $queryParams = [];
Severity: Major
Found in src/Buy/MarketplaceInsightsBeta/V1/Api/ItemSalesApi.php and 4 other locations - About 30 mins to fix
src/Buy/MarketplaceInsightsBeta/V1/Api/ItemSalesApi.php on lines 171..176
src/Buy/MarketplaceInsightsBeta/V1/Api/ItemSalesApi.php on lines 197..262
src/Buy/MarketplaceInsightsBeta/V1/Api/ItemSalesApi.php on lines 282..290
src/Buy/MarketplaceInsightsBeta/V1/Api/ItemSalesApi.php on lines 310..338

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

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

    public function getTransactionsAsync($x_ebay_c_marketplace_id = null, $filter = null, $limit = null, $offset = null, $sort = null)
    {
        return $this->getTransactionsAsyncWithHttpInfo($x_ebay_c_marketplace_id, $filter, $limit, $offset, $sort)
            ->then(
                function ($response) {
Severity: Major
Found in src/Sell/Finances/V1/Api/TransactionApi.php and 5 other locations - About 30 mins to fix
src/Sell/Feed/V1/Api/CustomerServiceMetricTaskApi.php on lines 723..731
src/Sell/Finances/V1/Api/PayoutApi.php on lines 774..782
src/Sell/Fulfillment/V1/Api/OrderApi.php on lines 527..535
src/Sell/Inventory/V1/Api/OfferApi.php on lines 1693..1701
src/Sell/Marketing/V1/Api/NegativeKeywordApi.php on lines 1258..1266

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

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

    public function getCustomerServiceMetricTasksAsync($date_range = null, $feed_type = null, $limit = null, $look_back_days = null, $offset = null)
    {
        return $this->getCustomerServiceMetricTasksAsyncWithHttpInfo($date_range, $feed_type, $limit, $look_back_days, $offset)
            ->then(
                function ($response) {
Severity: Major
Found in src/Sell/Feed/V1/Api/CustomerServiceMetricTaskApi.php and 5 other locations - About 30 mins to fix
src/Sell/Finances/V1/Api/PayoutApi.php on lines 774..782
src/Sell/Finances/V1/Api/TransactionApi.php on lines 518..526
src/Sell/Fulfillment/V1/Api/OrderApi.php on lines 527..535
src/Sell/Inventory/V1/Api/OfferApi.php on lines 1693..1701
src/Sell/Marketing/V1/Api/NegativeKeywordApi.php on lines 1258..1266

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

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

    public function getPayoutsAsync($x_ebay_c_marketplace_id = null, $filter = null, $limit = null, $offset = null, $sort = null)
    {
        return $this->getPayoutsAsyncWithHttpInfo($x_ebay_c_marketplace_id, $filter, $limit, $offset, $sort)
            ->then(
                function ($response) {
Severity: Major
Found in src/Sell/Finances/V1/Api/PayoutApi.php and 5 other locations - About 30 mins to fix
src/Sell/Feed/V1/Api/CustomerServiceMetricTaskApi.php on lines 723..731
src/Sell/Finances/V1/Api/TransactionApi.php on lines 518..526
src/Sell/Fulfillment/V1/Api/OrderApi.php on lines 527..535
src/Sell/Inventory/V1/Api/OfferApi.php on lines 1693..1701
src/Sell/Marketing/V1/Api/NegativeKeywordApi.php on lines 1258..1266

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

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

    public function getOffersAsync($format = null, $limit = null, $marketplace_id = null, $offset = null, $sku = null)
    {
        return $this->getOffersAsyncWithHttpInfo($format, $limit, $marketplace_id, $offset, $sku)
            ->then(
                function ($response) {
Severity: Major
Found in src/Sell/Inventory/V1/Api/OfferApi.php and 5 other locations - About 30 mins to fix
src/Sell/Feed/V1/Api/CustomerServiceMetricTaskApi.php on lines 723..731
src/Sell/Finances/V1/Api/PayoutApi.php on lines 774..782
src/Sell/Finances/V1/Api/TransactionApi.php on lines 518..526
src/Sell/Fulfillment/V1/Api/OrderApi.php on lines 527..535
src/Sell/Marketing/V1/Api/NegativeKeywordApi.php on lines 1258..1266

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

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

    public function getOrdersAsync($field_groups = null, $filter = null, $limit = null, $offset = null, $order_ids = null)
    {
        return $this->getOrdersAsyncWithHttpInfo($field_groups, $filter, $limit, $offset, $order_ids)
            ->then(
                function ($response) {
Severity: Major
Found in src/Sell/Fulfillment/V1/Api/OrderApi.php and 5 other locations - About 30 mins to fix
src/Sell/Feed/V1/Api/CustomerServiceMetricTaskApi.php on lines 723..731
src/Sell/Finances/V1/Api/PayoutApi.php on lines 774..782
src/Sell/Finances/V1/Api/TransactionApi.php on lines 518..526
src/Sell/Inventory/V1/Api/OfferApi.php on lines 1693..1701
src/Sell/Marketing/V1/Api/NegativeKeywordApi.php on lines 1258..1266

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

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

Avoid too many return statements within this method.
Open

            return $data;
Severity: Major
Found in src/Buy/Browse/V1/ObjectSerializer.php - About 30 mins to fix

    Avoid too many return statements within this method.
    Open

                        return new \DateTime($data);
    Severity: Major
    Found in src/Buy/Browse/V1/ObjectSerializer.php - About 30 mins to fix

      Avoid too many return statements within this method.
      Open

                      return null;
      Severity: Major
      Found in src/Buy/Browse/V1/ObjectSerializer.php - About 30 mins to fix

        Avoid too many return statements within this method.
        Open

                        return implode(',', $collection);
        Severity: Major
        Found in src/Buy/Browse/V1/ObjectSerializer.php - About 30 mins to fix

          Avoid too many return statements within this method.
          Open

                      return new \SplFileObject($filename, 'r');
          Severity: Major
          Found in src/Buy/Browse/V1/ObjectSerializer.php - About 30 mins to fix

            Avoid too many return statements within this method.
            Open

                    return $query;
            Severity: Major
            Found in src/Buy/Browse/V1/ObjectSerializer.php - About 30 mins to fix

              Avoid too many return statements within this method.
              Open

                      return (string) $data;
              Severity: Major
              Found in src/Buy/Browse/V1/ObjectSerializer.php - About 30 mins to fix

                Avoid too many return statements within this method.
                Open

                            return $data;
                Severity: Major
                Found in src/Buy/Browse/V1/ObjectSerializer.php - About 30 mins to fix

                  Avoid too many return statements within this method.
                  Open

                              return $data;
                  Severity: Major
                  Found in src/Buy/Browse/V1/ObjectSerializer.php - About 30 mins to fix

                    Avoid too many return statements within this method.
                    Open

                            return $instance;
                    Severity: Major
                    Found in src/Buy/Browse/V1/ObjectSerializer.php - About 30 mins to fix

                      Avoid too many return statements within this method.
                      Open

                                          return new \DateTime(self::sanitizeTimestamp($data));
                      Severity: Major
                      Found in src/Buy/Browse/V1/ObjectSerializer.php - About 30 mins to fix

                        Avoid too many return statements within this method.
                        Open

                                            return new \DateTime(self::sanitizeTimestamp($data));
                        Severity: Major
                        Found in src/Buy/Deal/V1/ObjectSerializer.php - About 30 mins to fix
                          Severity
                          Category
                          Status
                          Source
                          Language