Fix DB purge of expired password reset reqs

3 year old bug introduced when refactoring 2.x -> 3.0.
Never worked in the first place.
This commit is contained in:
Calvin Montgomery 2017-04-29 17:05:45 -07:00
parent 8e74b0c765
commit 089ac75e9a
2 changed files with 2 additions and 2 deletions

View File

@ -2,7 +2,7 @@
"author": "Calvin Montgomery", "author": "Calvin Montgomery",
"name": "CyTube", "name": "CyTube",
"description": "Online media synchronizer and chat", "description": "Online media synchronizer and chat",
"version": "3.35.3", "version": "3.35.4",
"repository": { "repository": {
"url": "http://github.com/calzoneman/sync" "url": "http://github.com/calzoneman/sync"
}, },

View File

@ -209,7 +209,7 @@ module.exports.cleanOldPasswordResets = function (callback) {
callback = blackHole; callback = blackHole;
} }
var query = "DELETE FROM aliases WHERE time < ?"; var query = "DELETE FROM password_reset WHERE expire < ?";
module.exports.query(query, [Date.now() - 24*60*60*1000], callback); module.exports.query(query, [Date.now() - 24*60*60*1000], callback);
}; };