Model/Action/OrderCaptureAction.php
protected function addComment($payment, $commentContent)
    {
        if ($commentContent) {
            $comment = oxNew(\OxidEsales\PayPalModule\Model\OrderPaymentComment::class);
            $comment->setComment($commentContent);

            $payment->addComment($comment);
        }
    }
protected function addComment($payment, $commentContent)
    {
        if ($commentContent) {
            $comment = oxNew(\OxidEsales\PayPalModule\Model\OrderPaymentComment::class);
            $comment->setComment($commentContent);

            $payment->addComment($comment);
        }
    }
protected function addComment ( $ payment , $ commentContent ) { if ( $ commentContent ) { $ comment = oxNew ( \ OxidEsales \ PayPalModule \ Model \ OrderPaymentComment :: class ) ; $ comment -> setComment ( $ commentContent ) ; $ payment -> addComment ( $ comment ) ; } }
Adds comment to given Payment object.

@param object $payment
@param string $comment
Adds comment to given Payment object .