1
1
mirror of https://github.com/kokonect-link/cherrypick synced 2024-11-01 07:35:57 +09:00

Fix users/search (#4505)

This commit is contained in:
MeiMei 2019-03-15 22:22:59 +09:00 committed by syuilo
parent e97951fc51
commit ee29ab95be

View File

@ -71,7 +71,7 @@ export default define(meta, async (ps, me) => {
.find({
host: null,
usernameLower: new RegExp('^' + escapeRegexp(ps.query.replace('@', '').toLowerCase())),
isSuspended: false
isSuspended: { $ne: true }
}, {
limit: ps.limit,
skip: ps.offset
@ -82,7 +82,7 @@ export default define(meta, async (ps, me) => {
.find({
host: { $ne: null },
usernameLower: new RegExp('^' + escapeRegexp(ps.query.replace('@', '').toLowerCase())),
isSuspended: false
isSuspended: { $ne: true }
}, {
limit: ps.limit - users.length
});