fix: perbaiki parseDate agar case-insensitive sehingga urutan tanggal notifikasi benar

This commit is contained in:
2026-06-08 14:42:27 +08:00
parent 789e4f84f1
commit 9dc4d8dc8d

View File

@@ -84,7 +84,7 @@ export default function Notification() {
} }
const parseDate = (str: string) => { const parseDate = (str: string) => {
const [d, m, y] = str.split(' ') const [d, m, y] = str.split(' ')
return new Date(Number(y), BULAN[m] ?? 0, Number(d)).getTime() return new Date(Number(y), BULAN[m?.toUpperCase()] ?? 0, Number(d)).getTime()
} }
const groups: Record<string, Props[]> = {} const groups: Record<string, Props[]> = {}