fix(lib): add default value for getDateRange

This commit is contained in:
Alexander Klein 2021-03-10 10:40:59 +01:00
parent 3cb748b29b
commit f6f14bf104

View File

@ -36,7 +36,7 @@ export function getLocalTime(t) {
return addMinutes(new Date(t), new Date().getTimezoneOffset()); return addMinutes(new Date(t), new Date().getTimezoneOffset());
} }
export function getDateRange(value, locale) { export function getDateRange(value, locale = 'en-US') {
const now = new Date(); const now = new Date();
const localeOptions = dateLocales[locale]; const localeOptions = dateLocales[locale];