upd: kode error pada api

This commit is contained in:
amel
2024-10-23 17:54:13 +08:00
parent 31e1d4fcc9
commit e59335176f
41 changed files with 193 additions and 233 deletions

View File

@@ -65,6 +65,6 @@ export async function GET(request: Request, context: { params: { id: string } })
return NextResponse.json({ success: true, data: fixMember })
} catch (error) {
return NextResponse.json({ success: false, message: "Gagal mendapatkan member, data tidak ditemukan", }, { status: 404 });
return NextResponse.json({ success: false, message: "Gagal mendapatkan anggota, data tidak ditemukan (error: 500)", }, { status: 500 });
}
}