Skip to content

Wrong totals sent to payment gateway when using free shipping coupon #2131

Description

@ablears

I've noticed customers being charged incorrect amounts through multiple payment gateways when using a free shipping coupon.

The issue occurs if the free shipping discount is greater than the total product price.

To replicate, add 2 quantity Aeropress + 1kg variant of this product.
http://creative-order.com.au/staging/coffeebird/shop/all-coffee/white-blend-espresso-roast/

Go to checkout: http://creative-order.com.au/staging/coffeebird/shop/checkout/

Enter coupon 'coffee' and postcode 0820.

You should see this

image

Note the discount amount is $109.90. The total price is $84.00.

Pay using Stripe credit card (in dev mode, so use 4242424242424242 and any in future expiration date and any 3 digit CVC). Or pay using 'Credit Card' option which is manual payments/test gateway.

Hey, look! You've been charged the discount amount ($109.90) not the total price ($84.00)!

image

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions