Skip to content

Commit

Permalink
Bail CapturePayment if is not mollie payment
Browse files Browse the repository at this point in the history
  • Loading branch information
mmaymo committed Jun 28, 2024
1 parent a890c42 commit f27dc87
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/MerchantCapture/Capture/Action/CapturePayment.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,11 @@ class CapturePayment extends AbstractPaymentCaptureAction
public function __invoke()
{
try {
$payment = $this->order->get_payment_method();
if (strpos($payment, 'mollie') === false ) {
return;
}

$paymentId = $this->order->get_meta('_mollie_payment_id');

if (!$paymentId) {
Expand Down

0 comments on commit f27dc87

Please sign in to comment.