Skip to content
This repository has been archived by the owner on Apr 19, 2022. It is now read-only.

Display and update shipping amount correctly #157

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

willock-stripe
Copy link
Collaborator

Fixes #156

This PR amends the logic for shipping rates:

  • Changing the shipping rates in the configuration file will be reflected in PaymentIntent and UI
  • Changing the selected shipping rate via the PaymentRequest button will update the PaymentIntent and UI

TODO:

  • Update other server languages

@willock-stripe willock-stripe marked this pull request as ready for review October 28, 2020 10:03
@@ -26,6 +27,11 @@ class Store {
);
}

async getDefaultShippingAmount() {
const config = await this.getConfig();
return config.shippingOptions[0].amount;
Copy link
Contributor

Choose a reason for hiding this comment

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

In practice shippingOptions[0] will just never be null or undefined?

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

Successfully merging this pull request may close these issues.

Shipping Rates from config file do not take effect in total price in checkout
2 participants