/** * Set refund transaction id to payment object for informational purposes * Candidate to be deprecated: * there can be multiple refunds per payment, thus payment.refund_transaction_id doesn't make big sense * * @param Invoice $invoice * @param Payment $payment * @return $this */ public function processBeforeRefund($invoice, $payment) { $payment->setRefundTransactionId($invoice->getTransactionId()); return $this; }