silvershop/silvershop-core

Guest Checkout Setup

peterkoopman opened this issue · 1 comments

Hope this is the right forum to post in - all the others seem to be pretty out of date.
I'm trying to set up a Guest Checkout, but when the user gets redirected back from the Payment Gateway, they get redirected to the Site Login page and can't go any further. As they don't have a login at this stage it doesn't work with the buy journey.
The Member check is in the init() method of the main Account Page controller, so it can't be overwritten.
I would suggest that this is not the best place to put it, but is there any workaround for this?

Are you sure the user gets redirected to the account page?
This should only happen, if there's a user that's logged in: https://github.com/silvershop/silvershop-core/blob/master/src/Model/Order.php#L522

After you finish an order, can you check whether you land on <accountpage>/order/<id> or <checkoutpage>/order/<id>? If there's no logged in user, you should land on <checkoutpage>/order/<id> and the problem might be something else…