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

Remove adjustment updates in Shipment#update_amounts #1435

Conversation

jhawthorn
Copy link
Contributor

@jhawthorn jhawthorn commented Sep 12, 2016

Previously calling Shipment#update_amounts (usually done by the OrderUpdater) would update the cost on the Shipment as well as call update! on all adjustments and update the Shipment's adjustment_total.

When used as part of an OrderUpdate this isn't necessary as the adjustments will be updated later in the process.

This relates to #1252 where @jordan-brough suggests we should no longer update adjustments outside of OrderUpdater.

Previously calling Shipment#update_amounts (usually done by the
OrderUpdater) would update the cost on the Shipment as well as call
update! on all adjustments and update the Shipment's adjustment_total.

When used as part of an OrderUpdate this isn't necessary as the
adjustments will be updated later in the process.
@jordan-brough
Copy link
Contributor

👍 nice!

@gmacdougall
Copy link
Member

👍

Thanks John!

@cbrunsdon
Copy link
Contributor

👍 🎆

@jordan-brough jordan-brough merged commit de697f7 into solidusio:master Sep 24, 2016
@jhawthorn jhawthorn deleted the remove_adjustment_update_in_update_amounts branch September 26, 2016 18:58
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.

4 participants