debug log

This commit is contained in:
ThatOneCalculator 2022-08-09 00:50:11 -07:00
parent 9a4f1cd3ac
commit 66290e572f

View File

@ -64,12 +64,11 @@ export default define(meta, paramDef, async (ps, user) => {
throw new ApiError(meta.errors.rtlDisabled);
}
}
console.log(`\n\n${m.recommendedInstances}\n\n`)
// .andWhere('(note.userHost IN (:instances)) OR (note.userHost IS NULL)', { instances: instances })
//#region Construct query
const query = makePaginationQuery(Notes.createQueryBuilder('note'),
ps.sinceId, ps.untilId, ps.sinceDate, ps.untilDate)
// Query where note.userHost is in recommended instances
.andWhere('(note.userHost IN (:instances)) OR (note.userHost IS NULL)', { instances: m.recommendedInstances })
// .andWhere(new Brackets(qb => {
// qb.where('note.userHost IN :instances', { instances: m.recommendedInstances })