From bcc5449e47956e9786646abf688a3161aa89912a Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 14 Apr 2018 14:22:58 +0900 Subject: [PATCH] =?UTF-8?q?=E3=83=AA=E3=83=A2=E3=83=BC=E3=83=88=E3=83=A6?= =?UTF-8?q?=E3=83=BC=E3=82=B6=E3=83=BC=E3=81=AF=E3=81=8A=E3=81=99=E3=81=99?= =?UTF-8?q?=E3=82=81=E3=83=A6=E3=83=BC=E3=82=B6=E3=83=BC=E3=81=AB=E5=90=AB?= =?UTF-8?q?=E3=82=81=E3=81=AA=E3=81=84=E3=82=88=E3=81=86=E3=81=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/server/api/endpoints/users/recommendation.ts | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/src/server/api/endpoints/users/recommendation.ts b/src/server/api/endpoints/users/recommendation.ts index 2de22da13e..e367e65a6c 100644 --- a/src/server/api/endpoints/users/recommendation.ts +++ b/src/server/api/endpoints/users/recommendation.ts @@ -30,15 +30,13 @@ module.exports = (params, me) => new Promise(async (res, rej) => { _id: { $nin: followingIds }, - $or: [ - { - 'lastUsedAt': { - $gte: new Date(Date.now() - ms('7days')) - } - }, { - host: { $ne: null } + $or: [{ + 'lastUsedAt': { + $gte: new Date(Date.now() - ms('7days')) } - ] + }, { + host: null + }] }, { limit: limit, skip: offset,