mirror of
https://github.com/jakejarvis/sofa.git
synced 2026-08-29 02:45:39 -04:00
Simplify auth, remove abstraction layers, add shadcn components
- Delete lib/api/errors.ts and lib/api/auth-guard.ts, inline NextResponse.json() error responses directly in route handlers - Replace non-standard amber CSS variables with primary/primary-foreground - Regenerate shadcn UI components with biome-ignore comments - Add CLAUDE.md for repository guidance - Update dependencies and pnpm lockfile Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
import type { NextRequest } from "next/server";
|
||||
import { NextResponse } from "next/server";
|
||||
import { badRequest } from "@/lib/api/errors";
|
||||
import { registerJobs } from "@/lib/jobs/registry";
|
||||
import { scheduler } from "@/lib/jobs/scheduler";
|
||||
|
||||
@@ -15,8 +14,9 @@ export async function POST(
|
||||
const jobNames = scheduler.getJobNames();
|
||||
|
||||
if (!jobNames.includes(name)) {
|
||||
return badRequest(
|
||||
`Unknown job: ${name}. Available: ${jobNames.join(", ")}`,
|
||||
return NextResponse.json(
|
||||
{ error: `Unknown job: ${name}. Available: ${jobNames.join(", ")}` },
|
||||
{ status: 400 },
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user