mollie / magento2

Mollie Payments for Magento 2
https://www.mollie.com
Other
101 stars 52 forks source link

Guest shopping cart not cleared completely from session after finishing order #560

Closed frank-bokdam closed 1 year ago

frank-bokdam commented 1 year ago

Describe the bug After completing an order with a mollie payment method the finished quote is still present somewhere in session it seems. When creating a new cart after finishing the order, in cart it all seems ok. As soon as you go to checkout -> previous quote is linked again.

Used versions

To Reproduce Steps to reproduce the behavior:

  1. Add product to cart
  2. Complete order using mollie payment method
  3. Create new cart with different product
  4. go to checkout page

Expected behavior I would expect the second product added in the quote at this point to show up in for example minicart.

Actual behavior The first product that was added to quote is actually showing up in checkout and is being used from this point further to process order / payment etc.

Additional context Looking at the database it looks like a new quote is actually created properly. Thus, it seems that while going to checkout page (controller) somehow the session is picking up the previous quote id again. I would assume this is not cleared properly from session. I did notice the clearQuote() method in magento Success controller is being hit. When pushing through and creating the second order It'll also be linked to the first quote. After doing this a few times, it'll result in multiple orders linked to the same quote in database.

Frank-Magmodules commented 1 year ago

HI @frank-bokdam ,

Thanks for opening this issue. After investigation with your input through Slack (wherefore thanks!), we found out that this was caused by the fact that webhooks were disabled in your (development) environment. In a regular environment, this should not happen and that’s why we are closing this issue. Feel free to reopen it if you have any questions.

Esteraa commented 1 year ago

Hi @Frank-Magmodules Maybe we can re-open the issue as its not solved yet. I spoke with my colleague @frank-bokdam and the webhooks setting is enabled on live + the testing environment where the problem is still active. I think we still need to investigate the issue, because the problem is still there. I would be happy to help and contacted one of your colleagues through Slack also.

Frank-Magmodules commented 1 year ago

HI @Esteraa & @frank-bokdam ,

We are happy to share that we've just released the new 2.17.0 version where we now have fully fixed this issue. Thank you for opening this issue and for your patience. We are closing this issue now but please feel free to reopen the issue if you need any help on this.