Skip to content

Commit 2408c96

Browse files
committed
fix: review
1 parent 261c88d commit 2408c96

File tree

1 file changed

+1
-22
lines changed

1 file changed

+1
-22
lines changed

apps/meteor/client/views/room/contextualBar/ExportMessages/useDownloadExportMutation.ts

Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -42,28 +42,7 @@ export const useDownloadExportMutation = () => {
4242
mutationFn: async ({ mids }: { mids: IMessage['_id'][] }) => {
4343
const messages = Messages.find(
4444
{
45-
$and: [
46-
{
47-
$or: [{ _id: { $in: mids } }, { tmid: { $in: mids } }],
48-
},
49-
{
50-
$or: [
51-
{
52-
attachments: {
53-
$exists: true,
54-
$elemMatch: {
55-
type: 'file',
56-
},
57-
},
58-
},
59-
{
60-
attachments: {
61-
$exists: false,
62-
},
63-
},
64-
],
65-
},
66-
],
45+
$or: [{ _id: { $in: mids } }, { tmid: { $in: mids } }],
6746
},
6847
messagesFields,
6948
).fetch();

0 commit comments

Comments
 (0)