mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
delete cached per_kg preference for all weight calculators
This commit is contained in:
@@ -4,6 +4,7 @@ class UpdateWeightCalculators < ActiveRecord::Migration
|
||||
calculator.preferred_unit_from_list = 'kg'
|
||||
calculator.preferred_per_unit = calculator.preferred_per_kg
|
||||
calculator.preferences.delete(:preferred_per_kg)
|
||||
Rails.cache.delete(calculator.preference_cache_key("preferred_per_kg"))
|
||||
calculator.save
|
||||
}
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user