Skip to content

Commit f25c0fd

Browse files
committed
chore: extend maxduration for download function
1 parent 02259a2 commit f25c0fd

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

pages/api/links/download/dataroom-document.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { getFileNameWithPdfExtension } from "@/lib/utils";
1010
import { getIpAddress } from "@/lib/utils/ip";
1111

1212
export const config = {
13-
maxDuration: 180,
13+
maxDuration: 300,
1414
};
1515

1616
export default async function handle(

pages/api/links/download/index.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ import prisma from "@/lib/prisma";
88
import { getFileNameWithPdfExtension } from "@/lib/utils";
99
import { getIpAddress } from "@/lib/utils/ip";
1010

11+
// This function can run for a maximum of 300 seconds
12+
export const config = {
13+
maxDuration: 300,
14+
};
15+
1116
export default async function handle(
1217
req: NextApiRequest,
1318
res: NextApiResponse,

0 commit comments

Comments
 (0)