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

fix: fetch updated redirect url before redirecting #1743

Merged
merged 1 commit into from
Jan 28, 2025

Conversation

SGrueber
Copy link
Collaborator

@SGrueber SGrueber commented Jan 24, 2025

PR Type

[x] Bugfix

What Is the Current Behavior?

A user who uses a redirect before checkout payment, is redirected to the payment service provider (PSP) using a redirect URL provided by the ICM server during the checkout process.
If the user cancels the checkout process afterwards and adds some product to the basket or changes the basket in any other way the redirect url is not calculated again. In the checkout process he will be redirected to the PSP with the outdated URL. After submitting the order an error occurs because the current basket value differs from the amount that has been authorized by the PSP.

What Is the New Behavior?

Before the user is redirected to the PSP during the checkout process a REST request is sent to the ICM to fetch the currently valid redirect url.

Does this PR Introduce a Breaking Change?

[x] No

Other Information

AB#97415
AB#103424

@SGrueber SGrueber requested a review from shauke January 24, 2025 16:05
@SGrueber SGrueber self-assigned this Jan 24, 2025
@SGrueber SGrueber added the bug Something isn't working label Jan 24, 2025
@SGrueber SGrueber added this to the 5.3 milestone Jan 24, 2025
* to the payment provider in case of redirect before checkout
@SGrueber SGrueber force-pushed the bugfix/refresh_redirect_url branch from ff653f0 to 7b1274d Compare January 24, 2025 16:32
Copy link
Collaborator

@shauke shauke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good as far as I can tell.
But a migration note might be good before merging

@shauke
Copy link
Collaborator

shauke commented Jan 27, 2025

Replaces #1720

@shauke shauke merged commit ea74674 into develop Jan 28, 2025
23 checks passed
@shauke shauke deleted the bugfix/refresh_redirect_url branch January 28, 2025 13:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants