diff --git a/app/jobs/marc_export_job.rb b/app/jobs/marc_export_job.rb index 5700bacc..cabbb300 100644 --- a/app/jobs/marc_export_job.rb +++ b/app/jobs/marc_export_job.rb @@ -8,7 +8,7 @@ def perform(theses) zip_file = MarcBatch.new(theses, marc_filename, zip_filename).build BatchMailer.marc_batch_email(zip_filename, zip_file, theses).deliver_now ensure - zip_file.close + zip_file.close if zip_file end end