Controller/PaymentController.php
public function isConfirmedByPayPal($basket)
    {
        $oldBasketAmount = $this->getSession()->getVariable("oepaypal-basketAmount");
        if (!$oldBasketAmount) {
            return false;
        }

        $payPalCheckValidator = oxNew(\OxidEsales\PayPalModule\Core\PayPalCheckValidator::class);
        $payPalCheckValidator->setNewBasketAmount($basket->getPrice()->getBruttoPrice());
        $payPalCheckValidator->setOldBasketAmount($oldBasketAmount);

        return $payPalCheckValidator->isPayPalCheckValid();
    }
public function isConfirmedByPayPal($basket)
    {
        $oldBasketAmount = $this->getSession()->getVariable("oepaypal-basketAmount");
        if (!$oldBasketAmount) {
            return false;
        }

        $payPalCheckValidator = oxNew(\OxidEsales\PayPalModule\Core\PayPalCheckValidator::class);
        $payPalCheckValidator->setNewBasketAmount($basket->getPrice()->getBruttoPrice());
        $payPalCheckValidator->setOldBasketAmount($oldBasketAmount);

        return $payPalCheckValidator->isPayPalCheckValid();
    }
public function isConfirmedByPayPal ( $ basket ) { $ oldBasketAmount = $ this -> getSession ( ) -> getVariable ( "oepaypal-basketAmount" ) ; if ( ! $ oldBasketAmount ) { return false ; } $ payPalCheckValidator = oxNew ( \ OxidEsales \ PayPalModule \ Core \ PayPalCheckValidator :: class ) ; $ payPalCheckValidator -> setNewBasketAmount ( $ basket -> getPrice ( ) -> getBruttoPrice ( ) ) ; $ payPalCheckValidator -> setOldBasketAmount ( $ oldBasketAmount ) ; return $ payPalCheckValidator -> isPayPalCheckValid ( ) ; }
Detects if current payment was already successfully processed by PayPal

@param \OxidEsales\Eshop\Application\Model\Basket $basket basket object

@return bool
Detects if current payment was already successfully processed by PayPal