<p><strike>having the same issue (also commerce 3.4.15) when the lineItem's tax class gets changed via adjuster (-&gt; no change of totalPrice tho because tax is included in product price)</strike></p>
<p>solved -&gt; error in custom function</p>

CC BY-SA 4.0
2022-06-24T12:06:02.657Z
2022-06-24T14:03:52.913Z
2022-06-24T14:03:52.913Z
jarheadcore
<p>In a current project we need more complex logic to determine when to set the VAT to 0%, so we do this with an adjuster added through a module.</p>
<p>We are using the exact method described on <a href="https://craftcms.com/docs/commerce/3.x/extend/adjusters.html#replacing-an-adjuster" rel="nofollow noreferrer">https://craftcms.com/docs/commerce/3.x/extend/adjusters.html#replacing-an-adjuster</a> (The only differences are that we use some business logic to decide when the adjuster is relevant, and that our adjuster applies to the Tax of the whole order, so we don't set a line item)</p>
<p>This used to work, but since a recent update (Commerce 3.2.7 to 3.4.15), we always get an error when this adjuster if applied when the user submits to the 'commerce/payments/pay' action. The error is 'Something changed with the order before payment, please review your order and submit payment again.'</p>
<p>When the adjuster is not used, payment proceeds as normal.</p>
<p>If I check the code, it seems that this happens because of the 'if($totalPriceChanged' check in the PaymentsController class.</p>
<p>Have there been recent changes to the order validation that mean we need to approach this differently, or is there something else that I am missing?</p>
<p>Thanks!</p>

<plugin-craftcommerce><order><adjusters>
Craft Commerce: Replacing Adjuster causes error "Something changed with the order before payment, please review your order and submit payment again."
# Craft Commerce: Replacing Adjuster causes error "Something changed with the order before payment, please review your order and submit payment again."

(Asked by: username_0 on 2022-06-15)

In a current project we need more complex logic to determine when to set the VAT to 0%, so we do this with an adjuster added through a module.

We are using the exact method described on <https://craftcms.com/docs/commerce/3.x/extend/adjusters.html#replacing-an-adjuster> (The only differences are that we use some business logic to decide when the adjuster is relevant, and that our adjuster applies to the Tax of the whole order, so we don't set a line item)

This used to work, but since a recent update (Commerce 3.2.7 to 3.4.15), we always get an error when this adjuster if applied when the user submits to the 'commerce/payments/pay' action. The error is 'Something changed with the order before payment, please review your order and submit payment again.'

When the adjuster is not used, payment proceeds as normal.

If I check the code, it seems that this happens because of the 'if($totalPriceChanged' check in the PaymentsController class.

Have there been recent changes to the order validation that mean we need to approach this differently, or is there something else that I am missing?

Thanks!

**Tags:** plugin-craftcommerce, order, adjusters

---

## 1 answers

### Answer by username_1 on 2022-06-24. Score: 1

having the same issue (also commerce 3.4.15) when the lineItem's tax class gets changed via adjuster (-> no change of totalPrice tho because tax is included in product price)

solved -> error in custom function


---

