Always use purge_later

This commit is contained in:
Paul Chavard 2019-05-21 11:36:19 +02:00
parent 3a5a051018
commit 4a9ef5d12e
3 changed files with 3 additions and 3 deletions

View file

@ -143,7 +143,7 @@ module Gestionnaires
def purge_champ_piece_justificative
@champ = dossier.champs_private.find(params[:champ_id])
@champ.piece_justificative_file.purge
@champ.piece_justificative_file.purge_later
flash.notice = 'La pièce jointe a bien été supprimée.'
end

View file

@ -239,7 +239,7 @@ module Users
def purge_champ_piece_justificative
@champ = dossier.champs.find(params[:champ_id])
@champ.piece_justificative_file.purge
@champ.piece_justificative_file.purge_later
flash.notice = 'La pièce jointe a bien été supprimée.'
end

View file

@ -40,7 +40,7 @@ class Champs::PieceJustificativeChamp < Champ
end
if errors.present?
piece_justificative_file.purge
piece_justificative_file.purge_later
end
errors