From 338f04b2f2f14fbaf21cedab60e14acbe1173664 Mon Sep 17 00:00:00 2001 From: Matt Wright Date: Sun, 16 Sep 2012 23:01:35 -0400 Subject: [PATCH] polish --- flask_security/views.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/flask_security/views.py b/flask_security/views.py index ae0dc44..73f8071 100644 --- a/flask_security/views.py +++ b/flask_security/views.py @@ -132,6 +132,7 @@ def register(): def send_login(): """View function that sends login instructions for passwordless login""" + if request.json: form = PasswordlessLoginForm(MultiDict(request.json)) else: @@ -151,6 +152,7 @@ def send_login(): @anonymous_user_required def token_login(token): """View function that handles passwordless login via a token""" + expired, invalid, user = login_token_status(token) if invalid: @@ -171,6 +173,7 @@ def token_login(token): def send_confirmation(): """View function which sends confirmation instructions.""" + if request.json: form = SendConfirmationForm(MultiDict(request.json)) else: