Skip to content

Commit

Permalink
fix: timed out
Browse files Browse the repository at this point in the history
  • Loading branch information
PrinceBaghel258025 committed Nov 13, 2023
1 parent cefed4c commit 018ad51
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/app/api/generateImage/[chatid]/[orgid]/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { chats } from "@/lib/db/schema";
import { NextResponse } from "next/server";
import { generateChatImage } from "@/utils/apiHelper";
export const revalidate = 0; // disable cache
export const maxDuration = 60;

export async function POST(
request: Request,
Expand All @@ -14,7 +15,7 @@ export async function POST(
const body = await request.json();
console.log("prompt message", body.chatTitle);
const image_url = await generateChatImage(body.chatTitle as string, chatId);

await db
.update(chats)
.set({ image_url: image_url })
Expand Down

0 comments on commit 018ad51

Please sign in to comment.