From fea43747687cccad7a29c6f50ca8e1a19ab27386 Mon Sep 17 00:00:00 2001 From: Jakub Theimer <5587309+theimerj@users.noreply.github.com> Date: Mon, 25 Nov 2024 20:58:48 +0100 Subject: [PATCH 1/3] fix namespace --- src/Actions/AuthorizeStripePayment.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Actions/AuthorizeStripePayment.php b/src/Actions/AuthorizeStripePayment.php index d9d1556..0445885 100644 --- a/src/Actions/AuthorizeStripePayment.php +++ b/src/Actions/AuthorizeStripePayment.php @@ -6,8 +6,8 @@ use Dystcz\LunarApi\Domain\Payments\Contracts\PaymentIntent; use Lunar\Base\DataTransferObjects\PaymentAuthorize; use Lunar\Facades\Payments; -use Lunar\Models\Cart; -use Lunar\Models\Order; +use Lunar\Models\Contracts\Cart; +use Lunar\Models\Contracts\Order; class AuthorizeStripePayment { From 1229de8adc90ba5f15b7c5420e50037498ad65af Mon Sep 17 00:00:00 2001 From: Jakub Theimer <5587309+theimerj@users.noreply.github.com> Date: Mon, 25 Nov 2024 20:59:04 +0100 Subject: [PATCH 2/3] fix namespace, fail after all checks failed --- src/Jobs/Webhooks/WebhookHandler.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Jobs/Webhooks/WebhookHandler.php b/src/Jobs/Webhooks/WebhookHandler.php index 4ae4935..f1c545f 100644 --- a/src/Jobs/Webhooks/WebhookHandler.php +++ b/src/Jobs/Webhooks/WebhookHandler.php @@ -16,7 +16,7 @@ use Illuminate\Queue\SerializesModels; use Illuminate\Support\Facades\App; use Illuminate\Support\Facades\Config; -use Lunar\Models\Order; +use Lunar\Models\Contracts\Order; use Spatie\WebhookClient\Models\WebhookCall; use Stripe\Event; use Throwable; @@ -82,7 +82,7 @@ protected function findOrder(PaymentIntentContract $paymentIntent): Order return $order; } catch (Throwable $e) { - $this->fail($e); + // $this->fail($e); } try { @@ -90,7 +90,7 @@ protected function findOrder(PaymentIntentContract $paymentIntent): Order return $order; } catch (Throwable $e) { - $this->fail($e); + // $this->fail($e); } try { @@ -98,7 +98,7 @@ protected function findOrder(PaymentIntentContract $paymentIntent): Order return $order; } catch (Throwable $e) { - $this->fail($e); + // $this->fail($e); } $this->fail(new ModelNotFoundException('Order not found.')); From 5d2a5142c49e7976322e37725b5ad3c717cb2b25 Mon Sep 17 00:00:00 2001 From: Jakub Theimer <5587309+theimerj@users.noreply.github.com> Date: Mon, 25 Nov 2024 21:22:35 +0100 Subject: [PATCH 3/3] update testing env example --- .env.testing.example | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/.env.testing.example b/.env.testing.example index e2b33fb..34c7ec6 100644 --- a/.env.testing.example +++ b/.env.testing.example @@ -7,11 +7,15 @@ APP_URL=http://localhost DB_CONNECTION="sqlite" DB_DATABASE=":memory:" -REDIS_HOST=127.0.0.1 -REDIS_PASSWORD= +QUEUE_CONNECTION=sync +CACHE_DRIVER=array + +REDIS_CLIENT=phpredis +REDIS_HOST=localhost +REDIS_PASSWORD=null REDIS_PORT=6379 -PAYMENTS_TYPE=stripe +PAYMENT_DRIVER=stripe STRIPE_PUBLIC_KEY=pk_test_ STRIPE_SECRET_KEY=sk_test_