swellstores / swell-js

JS library for building storefronts and checkouts with Swell ecommerce.
https://swell.is
MIT License
138 stars 29 forks source link

Fix/stripe intent duplicates #158

Closed vstudenichnik-insoft closed 7 months ago

vstudenichnik-insoft commented 7 months ago

https://app.asana.com/0/1202306318068147/1206492754384816/f

Description

During the investigation, it turned out that some browser extensions led to the duplication of all Vault requests (not only POST /intents). Vault requests are executed using JSONP, which may not work correctly due to browser extensions. The fix is to use the fetch instead of <script src="***" /> request.

Testing

Risk Assessment

What is considered higher risk?
- a regression would negatively impact many customers / core functionality, e.g., - model framework - pricing / accounting / billing - payment integration - shared components - changes can't be undone so easily, e.g., - API endpoint or model changes - destructive actions (e.g. deletes) - migration on large # of collections/documents

For Reviewers

This code has been reviewed for:

awwit commented 7 months ago

You need to return the dist directory back to its original state.

vstudenichnik-insoft commented 7 months ago

The main changes are in this commit.