fix(backend): users/notesでsinceId指定時にデータベースにフォールバックするように修正
This commit is contained in:
parent
04971ca565
commit
7473b2854f
|
@ -72,6 +72,9 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
private idService: IdService,
|
||||
) {
|
||||
super(meta, paramDef, async (ps, me) => {
|
||||
const isRangeSpecified = (ps.sinceId != null || ps.sinceDate != null) && (ps.untilId != null || ps.untilDate != null);
|
||||
|
||||
if (isRangeSpecified || !(ps.sinceId != null || ps.sinceDate != null)) {
|
||||
const [
|
||||
userIdsWhoMeMuting,
|
||||
] = me ? await Promise.all([
|
||||
|
@ -148,6 +151,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
return await this.noteEntityService.packMany(timeline, me);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// fallback to database
|
||||
|
||||
|
|
Loading…
Reference in a new issue