Permalink
Browse files

revoke all sessions on email change

  • Loading branch information...
julianlam committed Jun 29, 2018
1 parent be0ef79 commit 7e6007e1464fbfeb53151002897466bbaeae2799
Showing with 1 addition and 0 deletions.
  1. +1 −0 src/user/profile.js
@@ -200,6 +200,7 @@ module.exports = function (User) {
async.series([
async.apply(db.sortedSetRemove, 'email:uid', oldEmail.toLowerCase()),
async.apply(db.sortedSetRemove, 'email:sorted', oldEmail.toLowerCase() + ':' + uid),
async.apply(User.auth.revokeAllSessions, uid),
], function (err) {
next(err);
});

0 comments on commit 7e6007e

Please sign in to comment.