Refactor Commentaire#notify_user
This commit is contained in:
parent
c07b83b266
commit
1235fce34a
1 changed files with 3 additions and 1 deletions
|
@ -20,6 +20,8 @@ class Commentaire < ActiveRecord::Base
|
||||||
end
|
end
|
||||||
|
|
||||||
def notify_user
|
def notify_user
|
||||||
NotificationMailer.new_answer(dossier).deliver_now! unless (current_user.try(:email) == dossier.user.email || email == 'contact@tps.apientreprise.fr')
|
if email != dossier.user.email && email != 'contact@tps.apientreprise.fr'
|
||||||
|
NotificationMailer.new_answer(dossier).deliver_now!
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue