mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-25 20:46:48 +00:00
This also replaces the after_save callback to after_update. We enforce a stock_item exists when modifying the variant and the stock_item gets created on variant's after_create. This means it's not possible to use any of the VariantStock's setters before the variant is persisted so executing the callback on creation is pointless.