aboutsummaryrefslogtreecommitdiff
path: root/src/web/controllers
diff options
context:
space:
mode:
authorCédric Bonhomme <cedric@cedricbonhomme.org>2016-03-02 08:25:52 +0100
committerCédric Bonhomme <cedric@cedricbonhomme.org>2016-03-02 08:25:52 +0100
commitb32ca6c0f5968f5e9f59847db5012e3ef7f98631 (patch)
tree83d6bd430c56ae552acb9577a53f0a2c9fbb7052 /src/web/controllers
parentminor update to the navbar (diff)
downloadnewspipe-b32ca6c0f5968f5e9f59847db5012e3ef7f98631.tar.gz
newspipe-b32ca6c0f5968f5e9f59847db5012e3ef7f98631.tar.bz2
newspipe-b32ca6c0f5968f5e9f59847db5012e3ef7f98631.zip
Code update. Some problems with CSRF token on Chromium...
Diffstat (limited to 'src/web/controllers')
-rw-r--r--src/web/controllers/user.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/web/controllers/user.py b/src/web/controllers/user.py
index ee2eb4c2..1b5c123e 100644
--- a/src/web/controllers/user.py
+++ b/src/web/controllers/user.py
@@ -1,9 +1,10 @@
-import random
-import hashlib
+import logging
from werkzeug import generate_password_hash, check_password_hash
from .abstract import AbstractController
from web.models import User
+logger = logging.getLogger(__name__)
+
class UserController(AbstractController):
_db_cls = User
@@ -11,7 +12,7 @@ class UserController(AbstractController):
def _handle_password(self, attrs):
if attrs.get('password'):
- attrs['pwdhash'] = generate_password_hash(attrs.pop('password'))
+ attrs['password'] = generate_password_hash(attrs.pop('password'))
elif 'password' in attrs:
del attrs['password']
bgstack15