diff options
| author | Jules Laplace <julescarbon@gmail.com> | 2018-01-11 15:03:35 +0100 |
|---|---|---|
| committer | Jules Laplace <julescarbon@gmail.com> | 2018-01-11 15:03:35 +0100 |
| commit | 2317eef0b983c1e21cf7be27c172cbc533701c51 (patch) | |
| tree | 78a1f690c14ab178cfac9d028b5851b833f3823d | |
| parent | bf3f6e6cc62ec1f651ba093c7763a9e59eec48b3 (diff) | |
fix pw
| -rw-r--r-- | bucky/util/auth.js | 2 |
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) { |
