mirror of
https://github.com/nocodb/nocodb.git
synced 2026-05-01 04:56:48 +00:00
fix(nc-gui): Cannot read properties of undefined (reading 'abbreviation')
This commit is contained in:
@@ -70,7 +70,13 @@ export function parseFlexibleDate(dateString: string) {
|
||||
|
||||
const timezones = getTimeZones({ includeUtc: true })
|
||||
export function getTimeZoneFromName(name: string = Intl.DateTimeFormat().resolvedOptions().timeZone) {
|
||||
return timezones.find((k) => isSameTimezone(k.name, name))
|
||||
const timezone = timezones.find((k) => isSameTimezone(k.name, name))
|
||||
|
||||
if (timezone) return timezone
|
||||
|
||||
console.log('Timezone not found', name)
|
||||
|
||||
return timezones.find((k) => k.group.includes(name))
|
||||
}
|
||||
|
||||
export function withTimezone(timezone?: string) {
|
||||
|
||||
Reference in New Issue
Block a user