Skip to content

Commit a717a0e

Browse files
authored
feat(config): Remove log for tz mismatch (#103492)
No longer needed, see https://linear.app/getsentry/issue/DAIN-594/time-series-chart-x-axis-ticks-are-not-aligned-to-dates-when-system Manual revert of #93330
1 parent d222c15 commit a717a0e

File tree

1 file changed

+1
-18
lines changed

1 file changed

+1
-18
lines changed

static/app/stores/configStore.tsx

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import * as Sentry from '@sentry/react';
21
import moment from 'moment-timezone';
32
import {createStore} from 'reflux';
43

@@ -12,8 +11,6 @@ interface ConfigStoreDefinition extends StrictStoreDefinition<Config> {
1211
set<K extends keyof Config>(key: K, value: Config[K]): void;
1312
}
1413

15-
const {warn} = Sentry.logger;
16-
1714
const storeConfig: ConfigStoreDefinition = {
1815
// When the app is booted we will _immediately_ hydrate the config store,
1916
// effecively ensuring this is not empty.
@@ -47,21 +44,7 @@ const storeConfig: ConfigStoreDefinition = {
4744
// TODO(dcramer): abstract this out of ConfigStore
4845
if (this.state.user) {
4946
this.state.user.permissions = new Set(this.state.user.permissions);
50-
51-
const systemTimeZone = moment.tz.guess();
52-
const userTimeZone = this.state.user.options.timezone;
53-
54-
const nowInSystemTimezone = moment.tz(undefined, systemTimeZone);
55-
const nowInUserTimezone = moment.tz(undefined, userTimeZone);
56-
57-
if (nowInSystemTimezone.utcOffset() !== nowInUserTimezone.utcOffset()) {
58-
warn('System time zone does not match user preferences time zone', {
59-
systemTimeZone,
60-
userTimeZone,
61-
});
62-
}
63-
64-
moment.tz.setDefault(userTimeZone);
47+
moment.tz.setDefault(this.state.user.options.timezone);
6548
}
6649

6750
this.trigger(this.state);

0 commit comments

Comments
 (0)