From 812539fc062446da57e27fc8ae5fbec2c26e8482 Mon Sep 17 00:00:00 2001 From: Ryan Park Date: Wed, 10 Oct 2012 16:09:45 -0700 Subject: [PATCH] When displaying the password link, show it as https, not http --- app.py | 3 ++- templates/base.html | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app.py b/app.py index 38fa577..4aafad1 100644 --- a/app.py +++ b/app.py @@ -56,7 +56,8 @@ def index(): def handle_password(): ttl, password = clean_input() key = set_password(password, ttl) - return render_template('confirm.html', password_link=request.url_root+key) + link = request.url_root.replace("http://", "https://") + key + return render_template('confirm.html', password_link=link) @application.route('/', methods=['GET']) def show_password(password_key): diff --git a/templates/base.html b/templates/base.html index 0c07d44..11fe82e 100644 --- a/templates/base.html +++ b/templates/base.html @@ -19,7 +19,7 @@ {% block content %}{% endblock %} - + {% block js %}{% endblock %}