craftcms / stripe

Sync and extend Stripe products and subscriptions.
MIT License
5 stars 0 forks source link

Allow guest checkout URLs and form actions #8

Closed nfourtythree closed 3 months ago

nfourtythree commented 3 months ago

Description

Currently, the Checkout::getCheckoutUrl() method and the CheckoutController::actionCheckout() endpoint both require that there be an actual Craft user to generate the session.

This PR updates the functionality to allow guest checkouts via the service method and controller action.

Due to the nature of how the method arguments are set it is a bit odd having to pass false, this is because currently, we are treating null as somewhat of a fallback which will try and seek out the user.

i-just commented 3 months ago

Closing in favour of https://github.com/craftcms/stripe/pull/9