Remove HTML part and 90 spaces from sent login email

This commit is contained in:
j3s 2020-05-12 00:02:55 -05:00 committed by forest
parent d06e07cfd3
commit bae9c2311d

View File

@ -50,15 +50,8 @@ def login():
current_app.config["FLASK_MAIL_INSTANCE"].send(
Message(
"Click This Link to Login to Capsul",
body=f"""
Navigate to {link} to log into capsul.
If you didn't request this, ignore this message.
""",
html=f"""
<p>Navigate to <a href="{link}">{link}</a> to log into capsul.</p>
<p>If you didn't request this, ignore this message.</p>
""",
body=(f"Navigate to {link} to log into Capsul.\n"
"\nIf you didn't request this, ignore this message."),
recipients=[email]
)
)
@ -83,4 +76,4 @@ def magiclink(token):
@bp.route("/logout")
def logout():
session.clear()
return redirect(url_for("index"))
return redirect(url_for("index"))