Passed
Pull Request — master (#608)
by Damir
05:59
created

SalesOrderAmendmentDependencyProvider   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 33
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 3
eloc 11
dl 0
loc 33
rs 10
c 1
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A getSalesOrderAmendmentQuoteExpanderPlugins() 0 4 1
A getSalesOrderAmendmentCreateValidationRulePlugins() 0 4 1
A getSalesOrderItemCollectorPlugins() 0 8 1
1
<?php
2
3
/**
4
 * This file is part of the Spryker Commerce OS.
5
 * For full license information, please view the LICENSE file that was distributed with this source code.
6
 */
7
8
declare(strict_types = 1);
9
10
namespace Pyz\Zed\SalesOrderAmendment;
11
12
use Spryker\Zed\CartNote\Communication\Plugin\SalesOrderAmendment\CartNoteSalesOrderItemCollectorPlugin;
13
use Spryker\Zed\ConfigurableBundleNote\Communication\Plugin\SalesOrderAmendment\ConfigurableBundleNoteSalesOrderItemCollectorPlugin;
14
use Spryker\Zed\SalesOrderAmendment\SalesOrderAmendmentDependencyProvider as SprykerSalesOrderAmendmentDependencyProvider;
15
use Spryker\Zed\SalesOrderAmendmentOms\Communication\Plugin\SalesOrderAmendment\OrderSalesOrderAmendmentValidatorRulePlugin;
16
use Spryker\Zed\SalesProductConfiguration\Communication\Plugin\SalesOrderAmendment\SalesProductConfigurationSalesOrderItemCollectorPlugin;
17
use Spryker\Zed\SalesServicePoint\Communication\Plugin\SalesOrderAmendment\SalesServicePointSalesOrderItemCollectorPlugin;
18
use Spryker\Zed\Shipment\Communication\Plugin\SalesOrderAmendment\ShipmentGroupsSalesOrderAmendmentQuoteExpanderPlugin;
19
use Spryker\Zed\Shipment\Communication\Plugin\SalesOrderAmendment\ShipmentSalesOrderItemCollectorPlugin;
20
21
class SalesOrderAmendmentDependencyProvider extends SprykerSalesOrderAmendmentDependencyProvider
22
{
23
    /**
24
     * @return list<\Spryker\Zed\SalesOrderAmendmentExtension\Dependency\Plugin\SalesOrderAmendmentValidatorRulePluginInterface>
25
     */
26
    protected function getSalesOrderAmendmentCreateValidationRulePlugins(): array
27
    {
28
        return [
0 ignored issues
show
Bug Best Practice introduced by
The expression return array(new Spryker...tValidatorRulePlugin()) returns the type array<integer,Spryker\Ze...entValidatorRulePlugin> which is incompatible with the documented return type Pyz\Zed\SalesOrderAmendment\list.
Loading history...
29
            new OrderSalesOrderAmendmentValidatorRulePlugin(),
30
        ];
31
    }
32
33
    /**
34
     * @return list<\Spryker\Zed\SalesOrderAmendmentExtension\Dependency\Plugin\SalesOrderItemCollectorPluginInterface>
35
     */
36
    protected function getSalesOrderItemCollectorPlugins(): array
37
    {
38
        return [
39
            new CartNoteSalesOrderItemCollectorPlugin(),
40
            new ShipmentSalesOrderItemCollectorPlugin(),
41
            new ConfigurableBundleNoteSalesOrderItemCollectorPlugin(),
42
            new SalesProductConfigurationSalesOrderItemCollectorPlugin(),
43
            new SalesServicePointSalesOrderItemCollectorPlugin(),
44
        ];
45
    }
46
47
    /**
48
     * @return list<\Spryker\Zed\SalesOrderAmendmentExtension\Dependency\Plugin\SalesOrderAmendmentQuoteExpanderPluginInterface>
49
     */
50
    protected function getSalesOrderAmendmentQuoteExpanderPlugins(): array
51
    {
52
        return [
0 ignored issues
show
Bug Best Practice introduced by
The expression return array(new Spryker...tQuoteExpanderPlugin()) returns the type array<integer,Spryker\Ze...entQuoteExpanderPlugin> which is incompatible with the documented return type Pyz\Zed\SalesOrderAmendment\list.
Loading history...
53
            new ShipmentGroupsSalesOrderAmendmentQuoteExpanderPlugin(),
54
        ];
55
    }
56
}
57