style : update position project

This commit is contained in:
lukman
2024-08-20 17:36:09 +08:00
parent 21c9aa4270
commit 07369e5db9
9 changed files with 349 additions and 22 deletions

View File

@@ -0,0 +1,28 @@
import { funGetUserByCookies } from "@/module/auth";
import { NextResponse } from "next/server";
export async function GET(request: Request) {
try {
const user = await funGetUserByCookies()
if (user.id == undefined) {
return NextResponse.json({ success: false, message: "Anda harus login untuk mengakses ini" }, { status: 401 });
}
const { searchParams } = new URL(request.url);
const id = searchParams.get("id");
return NextResponse.json({ success: true, data: null }, { status: 200 });
} catch (error) {
return NextResponse.json({ success: false, message: "" }, { status: 401 });
}
}