spree/spree — pull request #2981 by huoxito (2013-05-05 21:43:38+00:00)
Title: Clear tax adjustments only in TaxRate#adjust

> It doesn't make sense to remove all line item adjustments from
TaxRate#adjust. I'm not sure it makes sense to remove any adjustments at
all. Spree calls order#create_tax_charge!, which in turn destroy all
item adjustments, when:

>
* creating orders
* saving line items
* after transition to order delivery state

Guys yesterday I finally started working on a promo line item adjustment extension. Most of the code I'm extracting from a highly customized Spree app. This is one of the points I've noticed while trying to make the code work on Spree edge. Please let me know your thoughts.

I believe we should definitely get rid of the agressive ``order#clear_adjustments`` in ``TaxRate#adjust``. Maybe this could be the first step of a bigger refactoring. It doesn't sound right that a ``order#create_tax_charge!`` removes all tax charges before it create new ones. Looks confusing to me.