Code Duplication    Length = 10-14 lines in 3 locations

src/OroCRM/Bundle/MagentoBundle/ImportExport/Strategy/CartWithExistingCustomerStrategy.php 1 location

@@ 15-28 (lines=14) @@
12
    /**
13
     * {@inheritdoc}
14
     */
15
    public function process($importingCart)
16
    {
17
        if (!$this->hasContactInfo($importingCart)) {
18
            return null;
19
        }
20
21
        if (!$this->isProcessingAllowed($importingCart)) {
22
            $this->appendDataToContext(self::CONTEXT_CART_POST_PROCESS, $this->context->getValue('itemData'));
23
24
            return null;
25
        }
26
27
        return parent::process($importingCart);
28
    }
29
30
    /**
31
     * @param Cart $cart

src/OroCRM/Bundle/MagentoBundle/ImportExport/Strategy/NewsletterSubscriberWithExistingCustomerStrategy.php 1 location

@@ 15-24 (lines=10) @@
12
    /**
13
     * {@inheritdoc}
14
     */
15
    public function process($entity)
16
    {
17
        if (!$this->isProcessingAllowed($entity)) {
18
            $this->appendDataToContext(self::NEWSLETTER_SUBSCRIBER_POST_PROCESS, $this->context->getValue('itemData'));
19
20
            return null;
21
        }
22
23
        return parent::process($entity);
24
    }
25
26
    /**
27
     * @param NewsletterSubscriber $newsletterSubscriber

src/OroCRM/Bundle/MagentoBundle/ImportExport/Strategy/OrderWithExistingCustomerStrategy.php 1 location

@@ 20-29 (lines=10) @@
17
     *
18
     * {@inheritdoc}
19
     */
20
    public function process($importingOrder)
21
    {
22
        if (!$this->isProcessingAllowed($importingOrder)) {
23
            $this->appendDataToContext(self::CONTEXT_ORDER_POST_PROCESS, $this->context->getValue('itemData'));
24
25
            return null;
26
        }
27
28
        return parent::process($importingOrder);
29
    }
30
31
    /**
32
     * @param Order $order