Model/IPNPaymentBuilder.php
protected function addPaymentValidationInformation($requestOrderPayment, $orderPayment)
    {
        $lang = $this->getLang();

        $paymentValidator = $this->getOrderPaymentValidator();
        $paymentValidator->setRequestOrderPayment($requestOrderPayment);
        $paymentValidator->setOrderPayment($orderPayment);
        $paymentValidator->setLang($lang);

        $paymentIsValid = $paymentValidator->isValid();
        if (!$paymentIsValid) {
            $orderPayment->setIsValid($paymentIsValid);
            $comment = oxNew(\OxidEsales\PayPalModule\Model\OrderPaymentComment::class);
            $comment->setComment($paymentValidator->getValidationFailureMessage());
            $orderPayment->addComment($comment);
        }

        return $orderPayment;
    }
protected function addPaymentValidationInformation($requestOrderPayment, $orderPayment)
    {
        $lang = $this->getLang();

        $paymentValidator = $this->getOrderPaymentValidator();
        $paymentValidator->setRequestOrderPayment($requestOrderPayment);
        $paymentValidator->setOrderPayment($orderPayment);
        $paymentValidator->setLang($lang);

        $paymentIsValid = $paymentValidator->isValid();
        if (!$paymentIsValid) {
            $orderPayment->setIsValid($paymentIsValid);
            $comment = oxNew(\OxidEsales\PayPalModule\Model\OrderPaymentComment::class);
            $comment->setComment($paymentValidator->getValidationFailureMessage());
            $orderPayment->addComment($comment);
        }

        return $orderPayment;
    }
protected function addPaymentValidationInformation ( $ requestOrderPayment , $ orderPayment ) { $ lang = $ this -> getLang ( ) ; $ paymentValidator = $ this -> getOrderPaymentValidator ( ) ; $ paymentValidator -> setRequestOrderPayment ( $ requestOrderPayment ) ; $ paymentValidator -> setOrderPayment ( $ orderPayment ) ; $ paymentValidator -> setLang ( $ lang ) ; $ paymentIsValid = $ paymentValidator -> isValid ( ) ; if ( ! $ paymentIsValid ) { $ orderPayment -> setIsValid ( $ paymentIsValid ) ; $ comment = oxNew ( \ OxidEsales \ PayPalModule \ Model \ OrderPaymentComment :: class ) ; $ comment -> setComment ( $ paymentValidator -> getValidationFailureMessage ( ) ) ; $ orderPayment -> addComment ( $ comment ) ; } return $ orderPayment ; }
Adds payment validation information.

@param \OxidEsales\PayPalModule\Model\OrderPayment $requestOrderPayment
@param \OxidEsales\PayPalModule\Model\OrderPayment $orderPayment

@return \OxidEsales\PayPalModule\Model\OrderPayment
Adds payment validation information .