mirror of
https://iceshrimp.dev/iceshrimp/iceshrimp
synced 2024-11-29 07:18:08 +09:00
Better query
This commit is contained in:
parent
bf23c3da4a
commit
56049ed06e
@ -51,8 +51,15 @@ export default async (ctx: Koa.Context) => {
|
||||
|
||||
const query = {
|
||||
userId: user._id,
|
||||
$or: [ { visibility: 'public' }, { visibility: 'home' } ],
|
||||
text: { $ne: null } // exclude renote, but include quote
|
||||
$and: [{
|
||||
$or: [ { visibility: 'public' }, { visibility: 'home' } ]
|
||||
}, { // exclude renote, but include quote
|
||||
$or: [{
|
||||
text: { $ne: null }
|
||||
}, {
|
||||
mediaIds: { $ne: [] }
|
||||
}]
|
||||
}]
|
||||
} as any;
|
||||
|
||||
if (sinceId) {
|
||||
|
Loading…
Reference in New Issue
Block a user