summaryrefslogtreecommitdiff
path: root/bucky
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2018-01-11 15:03:35 +0100
committerJules Laplace <julescarbon@gmail.com>2018-01-11 15:03:35 +0100
commit2317eef0b983c1e21cf7be27c172cbc533701c51 (patch)
tree78a1f690c14ab178cfac9d028b5851b833f3823d /bucky
parentbf3f6e6cc62ec1f651ba093c7763a9e59eec48b3 (diff)
fix pw
Diffstat (limited to 'bucky')
-rw-r--r--bucky/util/auth.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/bucky/util/auth.js b/bucky/util/auth.js
index ad8ce14..624c898 100644
--- a/bucky/util/auth.js
+++ b/bucky/util/auth.js
@@ -161,7 +161,7 @@ var auth = module.exports = {
var username = req.user.get('username')
var newPassword = auth.makePassword(username, req.body.newpassword)
res.user.set('password', newPassword)
- next()
+ res.user.save().then(() => next()).catch(err => res.send({ error: err }))
},
verifyLocalUser: function (username, password, done) {