parent
81d2c5a4a7
commit
5d56799070
21 changed files with 348 additions and 8 deletions
|
@ -76,11 +76,12 @@ export default class extends Endpoint<typeof meta, typeof paramDef> {
|
|||
throw new ApiError(meta.errors.noSuchAntenna);
|
||||
}
|
||||
|
||||
const limit = ps.limit + (ps.untilId ? 1 : 0); // untilIdに指定したものも含まれるため+1
|
||||
const noteIdsRes = await this.redisClient.xrevrange(
|
||||
`antennaTimeline:${antenna.id}`,
|
||||
ps.untilId ? this.idService.parse(ps.untilId).date.getTime() : '+',
|
||||
'-',
|
||||
'COUNT', ps.limit + 1); // untilIdに指定したものも含まれるため+1
|
||||
'COUNT', limit);
|
||||
|
||||
if (noteIdsRes.length === 0) {
|
||||
return [];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue