From 12dba39899a71ed0cc3a0f43e54a20d44d54466e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Raphael=20St=C3=A4bler?= Date: Fri, 21 Jun 2024 14:43:00 +0200 Subject: [PATCH] Fix db query --- src/commands/mail/oldaccounts.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/commands/mail/oldaccounts.ts b/src/commands/mail/oldaccounts.ts index 76b8bcc..5709c64 100644 --- a/src/commands/mail/oldaccounts.ts +++ b/src/commands/mail/oldaccounts.ts @@ -68,11 +68,11 @@ export default class OldAccounts extends Command { usersQuery['_id'] = { $in: Array.from(credentialSet), - isActive: true, - emailVerified: true, - oldAccountDeletionNoticeSent: {$ne: true}, - role: 'account-owner', }; + usersQuery['isActive'] = true; + usersQuery['emailVerified'] = true; + usersQuery['oldAccountDeletionNoticeSent'] = {$ne: true}; + usersQuery['role'] = 'account-owner'; } const userList = await db.collection('users').find(usersQuery).project({_id: 1}).toArray();