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

Stripe primary payment method out of sync with Commerce's primary payment source #235

Closed
timkelty opened this issue Apr 24, 2023 · 0 comments
Labels

Comments

@timkelty
Copy link
Contributor

Description

Commerce's concept of a customer's primary payment source does not properly sync with Stripe's primary payment method.

This is because every time we create a payment source in Stripe, we add it as the primary.

Conversely, Commerce will only default to an added source as primary if it is the only one.

Additionally, it is possible have an attached payment method in Stripe that is not primary.

Steps to reproduce

Using Commerce's example templates:

  1. With a new customer, add a 1st payment source
    • Note that Commerce defaults this to being your "Primary"
  2. Add a 2nd stripe payment source
    • Note that Commerce still considers the 1st to be primary
  3. Look in Stripe, and the customer's 2nd card will be primary, while Commerce says 1st is primary.

Additional info

  • Craft CMS version: 4.4.1
  • Stripe for Craft Commerce version: 3.1.0
  • PHP version: 8.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant