parseInt uid

This commit is contained in:
Barış Soner Uşaklı
2018-07-05 18:53:59 -04:00
parent 394edf83ec
commit 8eea6017fe

View File

@@ -48,8 +48,8 @@ module.exports = function (User) {
};
User.blocks.list = function (uid, callback) {
if (User.blocks._cache.has(uid)) {
return setImmediate(callback, null, User.blocks._cache.get(uid));
if (User.blocks._cache.has(parseInt(uid, 10))) {
return setImmediate(callback, null, User.blocks._cache.get(parseInt(uid, 10)));
}
db.getSortedSetRange('uid:' + uid + ':blocked_uids', 0, -1, function (err, blocked) {