From 206c041dd0e37e8b0a9a77949cd1948384848eeb Mon Sep 17 00:00:00 2001 From: Jakub Theimer <5587309+theimerj@users.noreply.github.com> Date: Sat, 16 Mar 2024 22:29:40 +0100 Subject: [PATCH 1/4] update packages --- composer.lock | 71 +++++++++++++++++++++++++-------------------------- 1 file changed, 35 insertions(+), 36 deletions(-) diff --git a/composer.lock b/composer.lock index 21537ff..f6c5d9d 100644 --- a/composer.lock +++ b/composer.lock @@ -4,20 +4,20 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "b5612a497506c6422f57900aa48054ab", + "content-hash": "1b1ad9ccc72efb84cae4106436ea28d5", "packages": [ { "name": "barryvdh/laravel-dompdf", - "version": "v2.1.0", + "version": "v2.1.1", "source": { "type": "git", "url": "https://github.com/barryvdh/laravel-dompdf.git", - "reference": "c8b8a8490e5f7348cf99054821fb248f103e7d24" + "reference": "cb37868365f9b937039d316727a1fced1e87b31c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/barryvdh/laravel-dompdf/zipball/c8b8a8490e5f7348cf99054821fb248f103e7d24", - "reference": "c8b8a8490e5f7348cf99054821fb248f103e7d24", + "url": "https://api.github.com/repos/barryvdh/laravel-dompdf/zipball/cb37868365f9b937039d316727a1fced1e87b31c", + "reference": "cb37868365f9b937039d316727a1fced1e87b31c", "shasum": "" }, "require": { @@ -69,7 +69,7 @@ ], "support": { "issues": "https://github.com/barryvdh/laravel-dompdf/issues", - "source": "https://github.com/barryvdh/laravel-dompdf/tree/v2.1.0" + "source": "https://github.com/barryvdh/laravel-dompdf/tree/v2.1.1" }, "funding": [ { @@ -81,7 +81,7 @@ "type": "github" } ], - "time": "2024-03-04T08:18:20+00:00" + "time": "2024-03-15T12:48:39+00:00" }, { "name": "brick/math", @@ -2647,16 +2647,16 @@ }, { "name": "laravel/framework", - "version": "v10.48.2", + "version": "v10.48.3", "source": { "type": "git", "url": "https://github.com/laravel/framework.git", - "reference": "32a8bb151d748b579c3794dea53b56bd40dfbbd3" + "reference": "5791c052b41c6b593556adc687076bfbdd13c501" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/framework/zipball/32a8bb151d748b579c3794dea53b56bd40dfbbd3", - "reference": "32a8bb151d748b579c3794dea53b56bd40dfbbd3", + "url": "https://api.github.com/repos/laravel/framework/zipball/5791c052b41c6b593556adc687076bfbdd13c501", + "reference": "5791c052b41c6b593556adc687076bfbdd13c501", "shasum": "" }, "require": { @@ -2850,7 +2850,7 @@ "issues": "https://github.com/laravel/framework/issues", "source": "https://github.com/laravel/framework" }, - "time": "2024-03-12T16:35:43+00:00" + "time": "2024-03-15T10:17:07+00:00" }, { "name": "laravel/pint", @@ -3302,16 +3302,16 @@ }, { "name": "league/flysystem", - "version": "3.25.0", + "version": "3.25.1", "source": { "type": "git", "url": "https://github.com/thephpleague/flysystem.git", - "reference": "4c44347133618cccd9b3df1729647a1577b4ad99" + "reference": "abbd664eb4381102c559d358420989f835208f18" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/4c44347133618cccd9b3df1729647a1577b4ad99", - "reference": "4c44347133618cccd9b3df1729647a1577b4ad99", + "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/abbd664eb4381102c559d358420989f835208f18", + "reference": "abbd664eb4381102c559d358420989f835208f18", "shasum": "" }, "require": { @@ -3376,7 +3376,7 @@ ], "support": { "issues": "https://github.com/thephpleague/flysystem/issues", - "source": "https://github.com/thephpleague/flysystem/tree/3.25.0" + "source": "https://github.com/thephpleague/flysystem/tree/3.25.1" }, "funding": [ { @@ -3388,20 +3388,20 @@ "type": "github" } ], - "time": "2024-03-09T17:06:45+00:00" + "time": "2024-03-16T12:53:19+00:00" }, { "name": "league/flysystem-local", - "version": "3.23.1", + "version": "3.25.1", "source": { "type": "git", "url": "https://github.com/thephpleague/flysystem-local.git", - "reference": "b884d2bf9b53bb4804a56d2df4902bb51e253f00" + "reference": "61a6a90d6e999e4ddd9ce5adb356de0939060b92" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/flysystem-local/zipball/b884d2bf9b53bb4804a56d2df4902bb51e253f00", - "reference": "b884d2bf9b53bb4804a56d2df4902bb51e253f00", + "url": "https://api.github.com/repos/thephpleague/flysystem-local/zipball/61a6a90d6e999e4ddd9ce5adb356de0939060b92", + "reference": "61a6a90d6e999e4ddd9ce5adb356de0939060b92", "shasum": "" }, "require": { @@ -3435,8 +3435,7 @@ "local" ], "support": { - "issues": "https://github.com/thephpleague/flysystem-local/issues", - "source": "https://github.com/thephpleague/flysystem-local/tree/3.23.1" + "source": "https://github.com/thephpleague/flysystem-local/tree/3.25.1" }, "funding": [ { @@ -3448,7 +3447,7 @@ "type": "github" } ], - "time": "2024-01-26T18:25:23+00:00" + "time": "2024-03-15T19:58:44+00:00" }, { "name": "league/glide", @@ -10256,16 +10255,16 @@ }, { "name": "orchestra/testbench-core", - "version": "v8.23.0", + "version": "v8.23.1", "source": { "type": "git", "url": "https://github.com/orchestral/testbench-core.git", - "reference": "35936ff29b42439fda75dbb635cc57e113f17c98" + "reference": "6c1d546c8864b0cb6304f584a709be7b1965e978" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/orchestral/testbench-core/zipball/35936ff29b42439fda75dbb635cc57e113f17c98", - "reference": "35936ff29b42439fda75dbb635cc57e113f17c98", + "url": "https://api.github.com/repos/orchestral/testbench-core/zipball/6c1d546c8864b0cb6304f584a709be7b1965e978", + "reference": "6c1d546c8864b0cb6304f584a709be7b1965e978", "shasum": "" }, "require": { @@ -10344,7 +10343,7 @@ "issues": "https://github.com/orchestral/testbench/issues", "source": "https://github.com/orchestral/testbench-core" }, - "time": "2024-03-13T04:02:37+00:00" + "time": "2024-03-15T12:13:59+00:00" }, { "name": "orchestra/workbench", @@ -11843,16 +11842,16 @@ }, { "name": "psy/psysh", - "version": "v0.12.0", + "version": "v0.12.1", "source": { "type": "git", "url": "https://github.com/bobthecow/psysh.git", - "reference": "750bf031a48fd07c673dbe3f11f72362ea306d0d" + "reference": "39621c73e0754328252f032c6997b983afc50431" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/bobthecow/psysh/zipball/750bf031a48fd07c673dbe3f11f72362ea306d0d", - "reference": "750bf031a48fd07c673dbe3f11f72362ea306d0d", + "url": "https://api.github.com/repos/bobthecow/psysh/zipball/39621c73e0754328252f032c6997b983afc50431", + "reference": "39621c73e0754328252f032c6997b983afc50431", "shasum": "" }, "require": { @@ -11916,9 +11915,9 @@ ], "support": { "issues": "https://github.com/bobthecow/psysh/issues", - "source": "https://github.com/bobthecow/psysh/tree/v0.12.0" + "source": "https://github.com/bobthecow/psysh/tree/v0.12.1" }, - "time": "2023-12-20T15:28:09+00:00" + "time": "2024-03-15T03:22:57+00:00" }, { "name": "rector/rector", From 6586e5fb6ecf3a8bee3672a7ec4c00b972824c9f Mon Sep 17 00:00:00 2001 From: Jakub Theimer <5587309+theimerj@users.noreply.github.com> Date: Sat, 16 Mar 2024 22:29:50 +0100 Subject: [PATCH 2/4] set automatic payment methods to false --- tests/TestCase.php | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/TestCase.php b/tests/TestCase.php index 0116ae9..0f7bf31 100644 --- a/tests/TestCase.php +++ b/tests/TestCase.php @@ -123,6 +123,7 @@ public function getEnvironmentSetUp($app): void 'payment_intent' => env('STRIPE_WEBHOOK_SECRET'), ], ]); + Config::set('lunar-api.stripe.automatic_payment_methods', false); // Default payment driver Config::set('lunar.payments.default', 'stripe'); From c06da4e13c61c4299f2891626e984f49848d1fe2 Mon Sep 17 00:00:00 2001 From: Jakub Theimer <5587309+theimerj@users.noreply.github.com> Date: Sat, 16 Mar 2024 22:30:03 +0100 Subject: [PATCH 3/4] add back config option --- config/stripe.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/config/stripe.php b/config/stripe.php index 58bc3a4..65cffaa 100644 --- a/config/stripe.php +++ b/config/stripe.php @@ -22,4 +22,11 @@ | */ 'type' => 'stripe', + + /** + * Automatic payment methods + * + * Enable automatic payment methods. + */ + 'automatic_payment_methods' => true, ]; From c7505b1c5de1e471db14e152288cf9984211e3b4 Mon Sep 17 00:00:00 2001 From: Jakub Theimer <5587309+theimerj@users.noreply.github.com> Date: Sat, 16 Mar 2024 22:30:07 +0100 Subject: [PATCH 4/4] set default to true --- src/Managers/StripeManager.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Managers/StripeManager.php b/src/Managers/StripeManager.php index 09775f3..c5edb54 100644 --- a/src/Managers/StripeManager.php +++ b/src/Managers/StripeManager.php @@ -41,7 +41,7 @@ protected function buildIntent($value, $currencyCode, $shipping): PaymentIntent $intentData = array_merge( $intentData, - Config::get('lunar-api.stripe.automatic_payment_methods', false) + Config::get('lunar-api.stripe.automatic_payment_methods', true) ? ['automatic_payment_methods' => ['enabled' => true]] : ['payment_method_types' => Config::get('lunar-api.stripe.payment_method_types', ['card'])] );