mirror of
https://github.com/postgres/pgweb.git
synced 2025-07-25 16:02:27 +00:00
Send -bugs and -docs emails from noreply address
Sending from the submitters address runs afoul to DMARC and other restrictions. Instead, send the email from a defined noreply address. Instead, add the original submitter to both the Cc and the Reply-To header, to make sure they receive followups. Patch by Stephen, minor changes by Magnus
This commit is contained in:

committed by
Magnus Hagander

parent
48aadf6815
commit
dfd46afae4
@ -133,7 +133,7 @@ def commentform(request, itemid, version, filename):
|
||||
form = DocCommentForm(request.POST)
|
||||
if form.is_valid():
|
||||
send_template_mail(
|
||||
form.cleaned_data['email'],
|
||||
settings.DOCSREPORT_NOREPLY_EMAIL,
|
||||
settings.DOCSREPORT_EMAIL,
|
||||
'%s' % form.cleaned_data['shortdesc'],
|
||||
'docs/docsbugmail.txt', {
|
||||
@ -142,6 +142,8 @@ def commentform(request, itemid, version, filename):
|
||||
'details': form.cleaned_data['details'],
|
||||
},
|
||||
usergenerated=True,
|
||||
cc=form.cleaned_data['email'],
|
||||
replyto='%s, %s' % (form.cleaned_data['email'], settings.DOCSREPORT_NOREPLY_EMAIL),
|
||||
)
|
||||
return render_to_response('docs/docsbug_completed.html', {
|
||||
}, NavContext(request, 'docs'))
|
||||
|
Reference in New Issue
Block a user