Add a rake task to fix uploads with wrong extension.

This commit is contained in:
Guo Xiang Tan
2018-08-08 13:14:52 +08:00
parent 6c41b54b2e
commit 17047806b9
2 changed files with 85 additions and 0 deletions

View File

@ -710,3 +710,7 @@ task "uploads:analyze", [:cache_path, :limit] => :environment do |_, args|
puts "List of file paths @ #{path}"
puts "Duration: #{Time.zone.now - now} seconds"
end
task "uploads:fix_incorrect_extensions" => :environment do
UploadFixer.fix_extensions
end