feat(medusa): invalidate price selection caching within update request (#3553)

* feat: invalidate price selection caching on update

* feat: add `onVariantsPricesUpdate` to PriceSelectionStrategy

* fix: update units

* fix: import

* Create .changeset/tame-pillows-heal.md

* fix: address feedback

* refactor: make `onVariantsPricesUpdate` optional

---------

Co-authored-by: fPolic <frane@medusajs.com>
Co-authored-by: Oliver Windall Juhl <59018053+olivermrbl@users.noreply.github.com>
This commit is contained in:
Frane Polić
2023-03-28 11:18:13 +02:00
committed by GitHub
parent 455c56c4b3
commit 1ce3cc5ae4
10 changed files with 53 additions and 47 deletions
@@ -149,6 +149,7 @@ export default async (req, res) => {
currency_code: currencyCode,
customer_id: req.validatedQuery.customer_id,
include_discount_prices: true,
ignore_cache: true,
})
res.json({