add sort users

parent ecada0fe
......@@ -27,7 +27,7 @@ module.exports = function (User) {
return dbUtils.dbFindOne(User, {fb_login: fb_login});
},
getUserByIds : function (ids) {
return dbUtils.dbFind(User, { _id: { $in: ids }});
return dbUtils.dbFind(User, { _id: { $in: ids }}, {sort : {'username' : 1}});
},
createUser : function (password, accountType, mail, name, surname, meta) {
var newUser = {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment