Add automatic confirmation mail after changing e-mail adress.

This commit is contained in:
Patrick Jentsch 2019-07-09 13:27:13 +02:00
parent 640bcc2bf1
commit dec9efa074
3 changed files with 1 additions and 3 deletions

View File

@ -139,6 +139,7 @@ def profile():
current_user.confirmed = False
db.session.add(current_user)
db.session.commit()
resend_confirmation()
return redirect(url_for('auth.profile'))
return render_template('auth/profile.html.j2', form=form,
title='Profile')

View File

@ -1,5 +1,4 @@
<p>Dear {{ user.username }},</p>
<p>Welcome to <b>Opaque</b>!</p>
<p>To confirm your account please <a href="{{ url_for('auth.confirm', token=token, _external=True) }}">click here</a>.</p>
<p>Alternatively, you can paste the following link in your browser's address bar:</p>
<p>{{ url_for('auth.confirm', token=token, _external=True) }}</p>

View File

@ -1,7 +1,5 @@
Dear {{ user.username }},
Welcome to Opaque!
To confirm your account please click on the following link:
{{ url_for('auth.confirm', token=token, _external=True) }}