ability to email without footer

This commit is contained in:
Kyle Drake 2015-03-11 12:19:40 -04:00
parent 6da092aee7
commit 5450ab4e83
2 changed files with 20 additions and 3 deletions

View file

@ -5,7 +5,11 @@ class EmailWorker
def perform(args={})
unsubscribe_token = Site.email_unsubscribe_token args['to']
footer = "\n\n---\nYou are receiving this email because you have a Neocities site. If you would like to subscribe from Neocities emails, just visit this url:\nhttps://neocities.org/settings/unsubscribe_email?email=#{Rack::Utils.escape args['to']}&token=#{unsubscribe_token}"
if args['no_footer']
footer = ''
else
footer = "\n\n---\nYou are receiving this email because you have a Neocities site. If you would like to subscribe from Neocities emails, just visit this url:\nhttps://neocities.org/settings/unsubscribe_email?email=#{Rack::Utils.escape args['to']}&token=#{unsubscribe_token}"
end
Mail.deliver do
# TODO this is not doing UTF-8 properly.