increase screenshot ttl to outdated resumes

This commit is contained in:
Amruth Pillai
2026-01-25 00:27:58 +01:00
parent 92f6a6a16b
commit b5f4e9af46
4 changed files with 21 additions and 11 deletions
+4 -4
View File
@@ -15,8 +15,8 @@ export const printerRouter = {
.input(z.object({ id: z.string() }))
.output(z.object({ url: z.string() }))
.handler(async ({ input, context }) => {
const resume = await resumeService.getByIdForPrinter({ id: input.id });
const url = await printerService.printResumeAsPDF(resume);
const { id, data, userId } = await resumeService.getByIdForPrinter({ id: input.id });
const url = await printerService.printResumeAsPDF({ id, data, userId });
if (!context.user) {
await resumeService.statistics.increment({ id: input.id, downloads: true });
@@ -36,8 +36,8 @@ export const printerRouter = {
.input(z.object({ id: z.string() }))
.output(z.object({ url: z.string() }))
.handler(async ({ input }) => {
const resume = await resumeService.getByIdForPrinter({ id: input.id });
const url = await printerService.getResumeScreenshot(resume);
const { id, data, userId, updatedAt } = await resumeService.getByIdForPrinter({ id: input.id });
const url = await printerService.getResumeScreenshot({ id, data, userId, updatedAt });
return { url };
}),