Skip to content

Stop stripe provider from setting refund status directly#476

Open
YounesOMK wants to merge 1 commit intojazzband:mainfrom
YounesOMK:fix/stripe-partial-refund-status
Open

Stop stripe provider from setting refund status directly#476
YounesOMK wants to merge 1 commit intojazzband:mainfrom
YounesOMK:fix/stripe-partial-refund-status

Conversation

@YounesOMK
Copy link

Removed premature change_status(REFUNDED) from stripe provider,
BasePayment.refund() already handles this (same as cybersource/dummy providers).

Fixes #475

provider.refund(payment)

assert payment.status == PaymentStatus.REFUNDED
assert payment.status == PaymentStatus.CONFIRMED
Copy link
Author

Choose a reason for hiding this comment

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

this assertion is not really needed since were just checking the provider doesn't touch the status because its role is to just do the api call, but i think its a nice guard in case someone adds change_status back in the future

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 (and some other providers) partial refund sets status to refunded after first partial refund

1 participant