mirror of
https://github.com/Hestia-Homes/assessment-model.git
synced 2026-07-22 08:48:34 +00:00
13 lines
401 B
TypeScript
13 lines
401 B
TypeScript
import { NextResponse } from "next/server";
|
|
import { previewPlanDeletion } from "@/lib/services/propertyDeletion";
|
|
|
|
export async function POST(
|
|
_req: Request,
|
|
context: { params: Promise<{ id: string }> }
|
|
) {
|
|
const { id } = await context.params; // 👈 THIS IS THE FIX
|
|
const planId = Number(id);
|
|
const preview = await previewPlanDeletion(planId);
|
|
|
|
return NextResponse.json({ preview });
|
|
}
|