fix server logic for sending whitelabel emails.

This commit is contained in:
fiatjaf 2018-09-17 01:37:08 +00:00 committed by Cole
parent ef0a3ddd67
commit 122f4825e4
1 changed files with 2 additions and 3 deletions

View File

@ -292,14 +292,13 @@ class Form(DB.Model):
unconfirm_url=unconfirm)
# if there's a custom email template we should use it
# otherwise check if the user wants a new or old version of the email
if self.owner.has_feature('whitelabel') and self.template:
html, subject = self.template.render_body_and_subject(
data=data, host=self.host, keys=keys, now=now,
unconfirm_url=unconfirm)
fromname = self.template.from_name
# check if the user wants a new or old version of the email
if format == 'plain':
elif format == 'plain':
html = render_template('email/plain_form.html',
data=data, host=self.host, keys=keys, now=now,
unconfirm_url=unconfirm)