mollie / spree-mollie-gateway

Mollie payments for Spree Commerce.
https://www.mollie.com
16 stars 23 forks source link

Preserve order state when a payment expires on a paid order #62

Closed Oldharlem closed 5 years ago

Oldharlem commented 5 years ago

We observed that when people leave a payment link page to add something to their cart to later come back and create a new link, the old link causes some issues.

Since the payment link expires a callback will be issued. In the old situation this callback would reset the order to the payment state. But since the order has been paid for this is undesireable.

This PR prevents the order from being reset once its paid. Furthermore the order will be updated by the order updater after every state change since 1/10 orders did not update to their correct state after a callback. The shipment state would remain pending, hence stopping the order from moving forward in the process.