Code Duplication    Length = 10-10 lines in 2 locations

src/Eccube/Service/PurchaseFlow/Processor/PointProcessor.php 2 locations

@@ 120-129 (lines=10) @@
117
    /**
118
     * {@inheritdoc}
119
     */
120
    public function prepare(ItemHolderInterface $itemHolder, PurchaseContext $context)
121
    {
122
        if (!$this->supports($itemHolder)) {
123
            return;
124
        }
125
126
        // ユーザの保有ポイントを減算
127
        $Customer = $itemHolder->getCustomer();
128
        $Customer->setPoint($Customer->getPoint() - $itemHolder->getUsePoint());
129
    }
130
131
    /**
132
     * {@inheritdoc
@@ 142-151 (lines=10) @@
139
    /**
140
     * {@inheritdoc
141
     */
142
    public function rollback(ItemHolderInterface $itemHolder, PurchaseContext $context)
143
    {
144
        // 利用したポイントをユーザに戻す.
145
        if (!$this->supports($itemHolder)) {
146
            return;
147
        }
148
149
        $Customer = $itemHolder->getCustomer();
150
        $Customer->setPoint($Customer->getPoint() + $itemHolder->getUsePoint());
151
    }
152
153
    /*
154
     * Helper methods