Skip to content
Snippets Groups Projects
Commit c05de08a authored by dakkar's avatar dakkar
Browse files

prettier query for bubble timeline

I *think* this works; in my test instance (with no federated notes…)
the generated query looks correct, and PostgreSQL doesn't complain.
parent ca06e452
No related branches found
No related tags found
No related merge requests found
......@@ -79,9 +79,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
ps.sinceId, ps.untilId, ps.sinceDate, ps.untilDate)
.andWhere('note.visibility = \'public\'')
.andWhere('note.channelId IS NULL')
.andWhere(
`(note.userHost = ANY ('{"${instance.bubbleInstances.join('","')}"}'))`,
)
.andWhere('note.userHost IN (:...hosts)', { hosts: instance.bubbleInstances})
.innerJoinAndSelect('note.user', 'user')
.leftJoinAndSelect('note.reply', 'reply')
.leftJoinAndSelect('note.renote', 'renote')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment