From 540f5b647a7a147b7286a10a02ad4b9e90094ed1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20Beganovi=C4=87?= Date: Mon, 22 Mar 2021 11:14:56 +0100 Subject: [PATCH] uncomment the initialization of billing service --- app/PaymentDrivers/BaseDriver.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/PaymentDrivers/BaseDriver.php b/app/PaymentDrivers/BaseDriver.php index a9250582a112..cb639b5e219f 100644 --- a/app/PaymentDrivers/BaseDriver.php +++ b/app/PaymentDrivers/BaseDriver.php @@ -241,11 +241,11 @@ class BaseDriver extends AbstractPaymentDriver event(new PaymentWasCreated($payment, $payment->company, Ninja::eventVars())); -// if (property_exists($this->payment_hash->data, 'billing_context')) { -// $billing_subscription = \App\Models\BillingSubscription::find($this->payment_hash->data->billing_context->billing_subscription_id); -// -// (new BillingSubscriptionService($billing_subscription))->completePurchase($this->payment_hash); -// } + if (property_exists($this->payment_hash->data, 'billing_context')) { + $billing_subscription = \App\Models\BillingSubscription::find($this->payment_hash->data->billing_context->billing_subscription_id); + + (new BillingSubscriptionService($billing_subscription))->completePurchase($this->payment_hash); + } return $payment->service()->applyNumber()->save(); }