Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PW-2570] Do refunds based on original PSP reference instead of notifications PSP reference #29

Closed
acampos1916 opened this issue Aug 4, 2020 · 1 comment

Comments

@acampos1916
Copy link
Member

Describe the bug
There can be common edge cases when this fails. Let's take an iDeal payment as an example:
You start the payment, an offer is created, go back and open the app again, a new offer is created, as soon as you finish the payment the first offer is cancelled and an offer_closed notification is sent with X psp reference. For the payment you get an Authorisation notification with Y psp reference. If you are not lucky then the offer_closed notification is going to be the "last" notification for the order and then the psp reference won't match therefore the refund cannot be done.

To Reproduce
Steps to reproduce the behavior:

  1. You start the payment, an offer is created.
  2. Go back and open the app again, a new offer is created, as soon as you finish the payment the first offer is cancelled and an offer_closed notification is sent with X psp reference.
  3. For the payment you get an Authorisation notification with Y psp reference.

Expected behavior
It would be better to store the original pspreference for the order when the async notification from our server or the sync authorisation response from the API is processed.

@cyattilakiss
Copy link
Contributor

Duplicate: #17

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants