diff --git a/src/app/api/metrics/productive-hours/route.ts b/src/app/api/metrics/productive-hours/route.ts index 5bb62d383..839a900c4 100644 --- a/src/app/api/metrics/productive-hours/route.ts +++ b/src/app/api/metrics/productive-hours/route.ts @@ -223,7 +223,7 @@ export async function GET(req: NextRequest) { } else { const daysParam = searchParams.get("days"); const parsedDays = daysParam ? parseInt(daysParam, 10) : NaN; - days = isNaN(parsedDays) ? 90 : Math.max(1, Math.min(365, parsedDays)); + days = Number.isNaN(parsedDays) ? 90 : Math.max(1, Math.min(365, parsedDays)); } const accountId = searchParams.get("accountId"); diff --git a/src/app/api/project-tutor/route.ts b/src/app/api/project-tutor/route.ts index a9d803b15..e71433c1a 100644 --- a/src/app/api/project-tutor/route.ts +++ b/src/app/api/project-tutor/route.ts @@ -163,4 +163,5 @@ Give a clear, concise answer focused on interview preparation. Keep it under 200 console.error("Project tutor error:", error); return NextResponse.json({ error: "Something went wrong" }, { status: 500 }); } -} \ No newline at end of file +} +.catch(err => console.error("Promise.all failed:", err)); \ No newline at end of file diff --git a/src/app/api/user/export/route.ts b/src/app/api/user/export/route.ts index cdd04e3fe..8387e877b 100644 --- a/src/app/api/user/export/route.ts +++ b/src/app/api/user/export/route.ts @@ -306,3 +306,5 @@ export async function GET(req: NextRequest) { }, }); } + +.catch(err => console.error("Promise.all failed:", err)); \ No newline at end of file diff --git a/src/app/dashboard/repo-comparison/page.tsx b/src/app/dashboard/repo-comparison/page.tsx index d5a7ca7a7..245da6769 100644 --- a/src/app/dashboard/repo-comparison/page.tsx +++ b/src/app/dashboard/repo-comparison/page.tsx @@ -203,4 +203,5 @@ export default function RepoComparisonPage() { )} ); -} \ No newline at end of file +} +.catch(err => console.error("Promise.all failed:", err)); \ No newline at end of file