Add fix script to regenerate old posts with transparent backgrounds.

Fixes #1862. Very old posts with transparent backgrounds used black
instead of white backgrounds in thumbnails. This was changed in #603
(see also #1239), but the thumbnails were never regenerated.
This commit is contained in:
evazion
2021-01-04 20:28:21 -06:00
parent 79ee6a515d
commit 62d183ddf4

View File

@@ -0,0 +1,7 @@
#!/usr/bin/env ruby
require_relative "../../config/environment"
Post.system_tag_match("transparent_background id:<=1361925").find_each do |post|
post.regenerate_later!("resizes", User.system)
end