PiecesJustificativesService: less violent error message in case of virus
This commit is contained in:
parent
395c9d5bb1
commit
21d7a96062
2 changed files with 2 additions and 2 deletions
|
@ -8,7 +8,7 @@ class PiecesJustificativesService
|
|||
.partition { |_, content| ClamavService.safe_file?(content.path) }
|
||||
|
||||
errors = with_virus
|
||||
.map { |_, content| content.original_filename + ': <b>Virus détecté !!</b>' }
|
||||
.map { |_, content| content.original_filename + ' : virus détecté' }
|
||||
|
||||
errors += without_virus
|
||||
.map { |tpj, content| save_pj(content, dossier, tpj, user) }
|
||||
|
|
|
@ -47,7 +47,7 @@ describe PiecesJustificativesService do
|
|||
}
|
||||
end
|
||||
|
||||
it { expect(errors).to match(['bad_file: <b>Virus détecté !!</b>']) }
|
||||
it { expect(errors).to match(['bad_file : virus détecté']) }
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue