mirror of
https://github.com/twentyhq/twenty.git
synced 2024-12-23 20:13:21 +03:00
Fix DateTimeSettingsTimeZoneSelect (#7688)
Fixing [sentry](https://twenty-v7.sentry.io/issues/5990711011/?alert_rule_id=15135099&alert_type=issue¬ification_uuid=06fea945-1c24-4ee6-94f6-99f1d7f94010&project=4507072563183616&referrer=discord) _Cannot read properties of undefined (reading 'label')_
This commit is contained in:
parent
1492340079
commit
17ec538da5
@ -2,6 +2,7 @@ import { detectTimeZone } from '@/localization/utils/detectTimeZone';
|
||||
import { findAvailableTimeZoneOption } from '@/localization/utils/findAvailableTimeZoneOption';
|
||||
import { AVAILABLE_TIMEZONE_OPTIONS } from '@/settings/accounts/constants/AvailableTimezoneOptions';
|
||||
import { Select } from '@/ui/input/components/Select';
|
||||
import { isDefined } from '~/utils/isDefined';
|
||||
|
||||
type DateTimeSettingsTimeZoneSelectProps = {
|
||||
value?: string;
|
||||
@ -25,7 +26,9 @@ export const DateTimeSettingsTimeZoneSelect = ({
|
||||
value={value}
|
||||
options={[
|
||||
{
|
||||
label: `System settings - ${systemTimeZoneOption.label}`,
|
||||
label: isDefined(systemTimeZoneOption)
|
||||
? `System settings - ${systemTimeZoneOption.label}`
|
||||
: 'System settings',
|
||||
value: 'system',
|
||||
},
|
||||
...AVAILABLE_TIMEZONE_OPTIONS,
|
||||
|
Loading…
Reference in New Issue
Block a user