add: Bot Trending Toggle, Hide Bot in Timeline client option
This commit is contained in:
parent
fa5cf36602
commit
c21d255604
19 changed files with 90 additions and 1 deletions
|
|
@ -56,6 +56,7 @@ export const paramDef = {
|
|||
withFiles: { type: 'boolean', default: false },
|
||||
withRenotes: { type: 'boolean', default: true },
|
||||
withReplies: { type: 'boolean', default: false },
|
||||
withBots: { type: 'boolean', default: true },
|
||||
},
|
||||
required: [],
|
||||
} as const;
|
||||
|
|
@ -134,6 +135,8 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
.leftJoinAndSelect('renote.user', 'renoteUser')
|
||||
.leftJoinAndSelect('note.channel', 'channel');
|
||||
|
||||
if (!ps.withBots) query.andWhere('user.isBot = FALSE');
|
||||
|
||||
let timeline = await query.getMany();
|
||||
|
||||
timeline = timeline.filter(note => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue