aboutsummaryrefslogtreecommitdiff
path: root/src/web/views/session_mgmt.py
diff options
context:
space:
mode:
authorCédric Bonhomme <cedric@cedricbonhomme.org>2016-04-07 10:34:23 +0200
committerCédric Bonhomme <cedric@cedricbonhomme.org>2016-04-07 10:34:23 +0200
commite89f9101c2e394530b16835a9ca45552a5f38ba8 (patch)
treedea5cc8a0fceaa36cc9701bcc4eedb2808969112 /src/web/views/session_mgmt.py
parentBug fix. (diff)
downloadnewspipe-e89f9101c2e394530b16835a9ca45552a5f38ba8.tar.gz
newspipe-e89f9101c2e394530b16835a9ca45552a5f38ba8.tar.bz2
newspipe-e89f9101c2e394530b16835a9ca45552a5f38ba8.zip
Bug fix.
Diffstat (limited to 'src/web/views/session_mgmt.py')
-rw-r--r--src/web/views/session_mgmt.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/web/views/session_mgmt.py b/src/web/views/session_mgmt.py
index 06d31ed2..5e67513a 100644
--- a/src/web/views/session_mgmt.py
+++ b/src/web/views/session_mgmt.py
@@ -1,6 +1,7 @@
import json
import logging
+from werkzeug import generate_password_hash
from werkzeug.exceptions import NotFound
from flask import (render_template, flash, session, request,
url_for, redirect, current_app)
@@ -85,7 +86,8 @@ def signup():
form = SignupForm()
if form.validate_on_submit():
user = UserController().create(nickname=form.nickname.data,
- email=form.email.data, password=form.password.data)
+ email=form.email.data,
+ pwdhash=generate_password_hash(form.password.data))
login_user_bundle(user)
return redirect(url_for('home'))
bgstack15