Skip to content

Commit

Permalink
Merge pull request #43 from CodeChefVIT/staging
Browse files Browse the repository at this point in the history
Staging
  • Loading branch information
NishantGupt786 authored Oct 16, 2024
2 parents 2739f5f + 8398dc4 commit 0f60cea
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/app/api/selected-papers/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import { NextResponse } from "next/server";
import { connectToDatabase } from "@/lib/mongoose";
import Paper from "@/db/papers";

export const dynamic = "force-dynamic";

export async function GET() {
try {
await connectToDatabase();
Expand All @@ -17,7 +19,9 @@ export async function GET() {
{ status: 404 },
);
}
return NextResponse.json(selectedPapers, { status: 200 });
return NextResponse.json(selectedPapers, {
status: 200,
});
} catch (error) {
console.error("Error fetching papers:", error);
return NextResponse.json(
Expand Down

0 comments on commit 0f60cea

Please sign in to comment.