diff --git a/src/app/api/mobile/division/route.ts b/src/app/api/mobile/division/route.ts index 5e51415..5803958 100644 --- a/src/app/api/mobile/division/route.ts +++ b/src/app/api/mobile/division/route.ts @@ -322,7 +322,7 @@ export async function POST(request: Request) { data: dataNotifFilter }) - const tokenUnique = [...new Set(tokenDup.flat())]; + const tokenUnique = [...new Set(tokenDup.flat())].filter((v: any) => v != undefined && v != null && v != ""); await sendFCMNotificationMany({ token: tokenUnique, title: "Divisi Baru", diff --git a/src/app/api/version-app/route.ts b/src/app/api/version-app/route.ts index 8a0b1a2..796f16b 100644 --- a/src/app/api/version-app/route.ts +++ b/src/app/api/version-app/route.ts @@ -2,7 +2,7 @@ import { NextResponse } from "next/server"; export async function GET(request: Request) { try { - return NextResponse.json({ success: true, version: "1.7.5", tahap: "beta", update: "-api mobile; -tambah laporan pada project dan tugas divisi; -tambah upload link pada project dan tugas divisi; -tambah detail tanggal dan jam pada project dan tugas divisi" }, { status: 200 }); + return NextResponse.json({ success: true, version: "1.7.6", tahap: "beta", update: "-api mobile; -tambah laporan pada project dan tugas divisi; -tambah upload link pada project dan tugas divisi; -tambah detail tanggal dan jam pada project dan tugas divisi" }, { status: 200 }); } catch (error) { console.error(error); return NextResponse.json({ success: false, version: "Gagal mendapatkan version, coba lagi nanti (error: 500)", reason: (error as Error).message, }, { status: 500 });