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.
Description
Currently, the
Checkout::getCheckoutUrl()
method and theCheckoutController::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 treatingnull
as somewhat of a fallback which will try and seek out the user.