1111/**
1212 * Sales transaction resource model
1313 *
14- * @author Magento Core Team <core@magentocommerce.com>
1514 */
1615class Transaction extends EntityAbstract implements TransactionResourceInterface
1716{
@@ -34,6 +33,7 @@ protected function _construct()
3433
3534 /**
3635 * Update transactions in database using provided transaction as parent for them
36+ *
3737 * have to repeat the business logic to avoid accidental injection of wrong transactions
3838 *
3939 * @param \Magento\Sales\Model\Order\Payment\Transaction $transaction
@@ -149,7 +149,7 @@ protected function _beforeSave(\Magento\Framework\Model\AbstractModel $transacti
149149 $ parentId = (int )$ this ->_lookupByTxnId ($ orderId , $ paymentId , $ parentTxnId , $ idFieldName );
150150 if ($ parentId && $ txnType == 'authorization ' ) {
151151 $ transaction ->setData ('parent_id ' , $ parentId );
152- $ transaction ->setData ('txn_type ' ,\Magento \Sales \Model \Order \Payment \Transaction::TYPE_CAPTURE );
152+ $ transaction ->setData ('txn_type ' , \Magento \Sales \Model \Order \Payment \Transaction::TYPE_CAPTURE );
153153 }
154154 } else {
155155 $ result = $ this ->getParentId ($ orderId );
@@ -176,7 +176,7 @@ protected function _beforeSave(\Magento\Framework\Model\AbstractModel $transacti
176176 * @param int $orderId
177177 * @param int $paymentId
178178 * @param string $txnId
179- * @param mixed (array|string|object) $columns
179+ * @param mixed $columns (array|string|object) $columns
180180 * @param bool $isRow
181181 * @param string $txnType
182182 * @return array|string
@@ -234,7 +234,7 @@ protected function getParentId(int $orderId): array
234234 )->where (
235235 'order_id = ? ' ,
236236 $ orderId
237- )->order ('transaction_id ' ,'ASC ' )->limit (1 );
237+ )->order ('transaction_id ' , 'ASC ' )->limit (1 );
238238 return $ connection ->fetchAll ($ select );
239239 }
240240}
0 commit comments