diff --git a/src/user/search.js b/src/user/search.js index 198b027266..68f6afde62 100644 --- a/src/user/search.js +++ b/src/user/search.js @@ -81,6 +81,10 @@ module.exports = function (User) { } function filterAndSortUids(uids, data, callback) { + uids = uids.filter(function (uid) { + return parseInt(uid, 10); + }); + var fields = []; if (data.sortBy) {