diff --git a/src/groups.js b/src/groups.js index 02e24a41bb..802f4346e2 100644 --- a/src/groups.js +++ b/src/groups.js @@ -1147,6 +1147,8 @@ var async = require('async'), return Groups.getMembers(data.groupName, 0, -1, callback); } + query = query.toLowerCase(); + async.waterfall([ function(next) { Groups.getMembers(data.groupName, 0, -1, next); diff --git a/src/user/search.js b/src/user/search.js index e78a932106..9d8d3c2f38 100644 --- a/src/user/search.js +++ b/src/user/search.js @@ -77,6 +77,7 @@ module.exports = function(User) { if (!query) { return callback(null, []); } + query = query.toLowerCase(); var min = query; var max = query.substr(0, query.length - 1) + String.fromCharCode(query.charCodeAt(query.length - 1) + 1);