diff --git a/app/models/communication/website/imported/post.rb b/app/models/communication/website/imported/post.rb index e199cce4ad4b066cdee7c59478364f0417d53451..b743fad873b8078f0e38503dc6225cfd6b573161 100644 --- a/app/models/communication/website/imported/post.rb +++ b/app/models/communication/website/imported/post.rb @@ -110,8 +110,7 @@ class Communication::Website::Imported::Post < ApplicationRecord response = http.request(request) begin post.featured_image.attach(io: StringIO.new(response.body), filename: filename, content_type: 'image/jpeg') - ensure - tempfile.close! + rescue end end end