fix: cw execution will exclude all notes without cw

This commit is contained in:
anatawa12 2023-08-06 16:42:06 +09:00
parent 9a688dde0a
commit 91e0a59d55
No known key found for this signature in database
GPG Key ID: 9CA909848B8E4EA6
1 changed files with 5 additions and 2 deletions

View File

@ -68,8 +68,11 @@ export default class extends Endpoint<typeof meta, typeof paramDef> {
new Brackets(qb => {
qb.where('note.text NOT LIKE \'%おはよう%\'')
.andWhere('note.text NOT LIKE \'%:ohayo_nirila_misskey:%\'')
.andWhere('note.cw NOT LIKE \'%おはよう%\'')
.andWhere('note.cw NOT LIKE \'%:ohayo_nirila_misskey:%\'')
.andWhere(new Brackets(qb => {
qb.where('note.cw NOT LIKE \'%おはよう%\'')
.andWhere('note.cw NOT LIKE \'%:ohayo_nirila_misskey:%\'')
.orWhere('note.cw IS NULL');
}))
.orWhere('note.fileIds != \'{}\'');
}),
);