Skip to content

Commit

Permalink
added reply email
Browse files Browse the repository at this point in the history
  • Loading branch information
Manasa2850 committed Feb 4, 2021
1 parent b300979 commit 27948db
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions app/models/comment.rb
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,14 @@ def self.receive_mail(mail)
add_comment(mail, comment.nid, user, [true, comment.id])
end
end
else
email = mail.select { |s| s.match(/.*@.*/) }
ActionMailer::Base.mail(
from: "[email protected]", # @jywarren what should this be?
to: email,
subject: "Could not post your reply",
body: "Your reply wasn't posted since we couldn't find your account on publiclab.org. Please sign up on publiclab.org"
).deliver
end
end

Expand Down

0 comments on commit 27948db

Please sign in to comment.