aboutsummaryrefslogtreecommitdiff
path: root/pyaggr3g470r
diff options
context:
space:
mode:
Diffstat (limited to 'pyaggr3g470r')
-rw-r--r--pyaggr3g470r/views/views.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/pyaggr3g470r/views/views.py b/pyaggr3g470r/views/views.py
index e0086032..3d25f0bb 100644
--- a/pyaggr3g470r/views/views.py
+++ b/pyaggr3g470r/views/views.py
@@ -165,14 +165,18 @@ def login():
form = SigninForm()
if form.validate_on_submit():
+ print("Form OK!")
user = UserController().get(email=form.email.data)
login_user(user)
+ print("User loaded!")
g.user = user
session['email'] = form.email.data
identity_changed.send(current_app._get_current_object(),
identity=Identity(user.id))
+ print("Identity changed!")
flash(gettext("Logged in successfully."), 'success')
return redirect(url_for('home'))
+ print("Form not OK!!!")
return render_template('login.html', form=form)
bgstack15