discourse/app/jobs/onceoff/rebake_all_html_theme_fields.rb
Kyle Zhao 0f1afad6da FIX: extracted theme JavaScripts for multisite (#6502)
* FIX: extracted theme javascripts for multisite

* onceoff to rebake all theme fields
2018-10-18 17:05:34 +11:00

12 lines
274 B
Ruby

module Jobs
class RebakeAllHtmlThemeFields < Jobs::Onceoff
def execute_onceoff(args)
ThemeField.where(type_id: ThemeField.types[:html]).find_each do |theme_field|
theme_field.update(value_baked: nil)
end
Theme.clear_cache!
end
end
end