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

Remove usage of optional chaining and nullish coalescing operators #2667

Merged
merged 2 commits into from
Jul 28, 2023

Conversation

diegocurbelo
Copy link
Member

@diegocurbelo diegocurbelo commented Jul 26, 2023

Fixes #2599

Changes proposed in this Pull Request:

Description: The javascript files in the assets folder are not transpiled with webpack like we do with the client folder, this PR replaces some ES11 code from the stripe.js asset file with its ES5 equivalent version.

Testing instructions

  • Running the E2E test suite
  • Using the shortcode checkout test:
    • Complete a checkout using a normal credit card (4242 4242 4242 4242) (uses payment methods)
    • Complete a checkout using a 3DS credit card (4000 0027 6000 3184) (uses payment methods)
    • Complete a checkout using SEPA (uses sources)

  • Covered with tests (or have a good reason not to test in description ☝️)
  • Added changelog entry in both changelog.txt and readme.txt (or does not apply)
  • Tested on mobile (or does not apply)

Post merge

@diegocurbelo diegocurbelo self-assigned this Jul 26, 2023
@diegocurbelo diegocurbelo marked this pull request as ready for review July 26, 2023 23:25
Copy link
Contributor

@a-danae a-danae left a comment

Choose a reason for hiding this comment

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

LGTM 👍

The e2e tests passed, and the flows to test from the description worked as expected. The code looks good. Thanks!

@diegocurbelo diegocurbelo merged commit afa87e3 into develop Jul 28, 2023
33 checks passed
@diegocurbelo diegocurbelo deleted the fix/2599-remove-optional-chaining branch July 28, 2023 14:49
stoyan0v pushed a commit to SiteGround/woocommerce-gateway-stripe that referenced this pull request Oct 3, 2023
…oocommerce#2667)

* Remove usage of optional chaining and nullish coalescing operators
* Update readme and changelog
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.

Stripe breaks JS on older browsers (use of optional chaining ?. operator)
2 participants