mirror of
https://gitlab.com/soapbox-pub/ditto.git
synced 2025-12-06 11:29:46 +00:00
paginationSchema: fix problem with nostrNow() being called only at startup
This commit is contained in:
parent
cc751f03a7
commit
c80a9e5d9a
1 changed files with 1 additions and 1 deletions
|
|
@ -80,7 +80,7 @@ async function parseBody(req: Request): Promise<unknown> {
|
||||||
|
|
||||||
const paginationSchema = z.object({
|
const paginationSchema = z.object({
|
||||||
since: z.coerce.number().optional().catch(undefined),
|
since: z.coerce.number().optional().catch(undefined),
|
||||||
until: z.coerce.number().catch(nostrNow()),
|
until: z.lazy(() => z.coerce.number().catch(nostrNow())),
|
||||||
limit: z.coerce.number().min(0).max(40).catch(20),
|
limit: z.coerce.number().min(0).max(40).catch(20),
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue