FIX: show available details when rescuing error

This commit is contained in:
Arpit Jalan 2019-04-15 14:09:52 +05:30
parent 07b961ab13
commit 989325ea7c

View File

@ -32,7 +32,7 @@ task "avatars:clean" => :environment do
begin
optimized_image.destroy!
rescue => e
puts "", "Failed to cleanup avatar for #{user.username}", e, e.backtrace.join("\n")
puts "", "Failed to cleanup avatar (optimized_image_id: #{optimized_image.id}, optimized_image_url: #{optimized_image.url})", e, e.backtrace.join("\n")
end
putc "." if (i += 1) % 10 == 0
end