Fix test : do not send notification if commentaire is not saved
This commit is contained in:
parent
e99746639b
commit
6bf3b9edf8
1 changed files with 1 additions and 1 deletions
|
@ -42,7 +42,7 @@ class CommentairesController < ApplicationController
|
|||
flash.alert = "Veuillez rédiger un message ou ajouter une pièce jointe."
|
||||
end
|
||||
|
||||
notify_user_with_mail(@commentaire)
|
||||
notify_user_with_mail(@commentaire) if saved
|
||||
|
||||
if is_gestionnaire?
|
||||
unless current_gestionnaire.follow? @commentaire.dossier
|
||||
|
|
Loading…
Reference in a new issue