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 unnecessary redirect #206

Merged
merged 6 commits into from
Aug 3, 2021
Merged

Conversation

strangerkir
Copy link
Contributor

@strangerkir strangerkir commented Jul 27, 2021

Description

When enabling gateway don't redirect to it's settings if plugin already is in onboarded state.

Steps to test:

  1. Complete onboarding or fill out all the relevant API details.

  2. Go to WooCommerce > Settings > Payments.

  3. Scroll down to "PayPal" and make sure the toggle is in the disabled state.

  4. Click the toggle and make sure there is no redirection to the gateway settings page and the gateway is enabled.

  5. Go to the gateway settings and disconnect to return to the not onboarded state.

  6. Return to WooCommerce > Settings > Payments.

  7. Disable the PayPal gateway and try to enable it again.

  8. Make sure this time you were redirected to the gateway settings.

Documentation

  • This PR needs documentation (has the "Documentation" label).

Changelog entry

Fix unneeded redirection when enabling payment gateway and setup is already done.

Closes #190.

@strangerkir strangerkir marked this pull request as ready for review July 27, 2021 17:15
@strangerkir strangerkir requested a review from Dinamiko July 27, 2021 17:15
@strangerkir strangerkir marked this pull request as draft July 28, 2021 06:31
@strangerkir strangerkir marked this pull request as ready for review July 28, 2021 07:07
@Dinamiko Dinamiko merged commit ef4bdc7 into trunk Aug 3, 2021
@Dinamiko Dinamiko deleted the fix/PCP-186-fix-unnecessary-redirect branch August 3, 2021 10:09
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

Successfully merging this pull request may close these issues.

Clicking the toggle on Settings > Payments results in a (possibly unnecessary) redirect
2 participants