Fix my dumb code

This commit is contained in:
Lim Chee Aun 2024-08-20 20:34:42 +08:00
parent bcf8a9c6c7
commit 0dbc76c40a

View file

@ -19,9 +19,9 @@ const _DateTimeFormat = (opts) => {
...formatOpts,
};
try {
return Intl.DateTimeFormat(loc, opts);
return Intl.DateTimeFormat(loc, options);
} catch (e) {
return Intl.DateTimeFormat(undefined, opts);
return Intl.DateTimeFormat(undefined, options);
}
};
const DateTimeFormat = mem(_DateTimeFormat);