aboutsummaryrefslogtreecommitdiffstats
path: root/src/stores/AppStore.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/stores/AppStore.js')
-rw-r--r--src/stores/AppStore.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/stores/AppStore.js b/src/stores/AppStore.js
index 4ac8325d4..94ed308f3 100644
--- a/src/stores/AppStore.js
+++ b/src/stores/AppStore.js
@@ -15,6 +15,8 @@ import { gaEvent } from '../lib/analytics';
15 15
16import { getServiceIdsFromPartitions, removeServicePartitionDirectory } from '../helpers/service-helpers.js'; 16import { getServiceIdsFromPartitions, removeServicePartitionDirectory } from '../helpers/service-helpers.js';
17 17
18const debug = require('debug')('AppStore');
19
18const { app } = remote; 20const { app } = remote;
19 21
20const defaultLocale = DEFAULT_APP_SETTINGS.locale; 22const defaultLocale = DEFAULT_APP_SETTINGS.locale;
@@ -279,13 +281,15 @@ export default class AppStore extends Store {
279 } 281 }
280 282
281 _setLocale() { 283 _setLocale() {
282 const locale = this.stores.settings.all.locale; 284 const { locale } = this.stores.user.data;
283 285
284 if (locale && Object.prototype.hasOwnProperty.call(locales, locale) && locale !== this.locale) { 286 if (locale && Object.prototype.hasOwnProperty.call(locales, locale) && locale !== this.locale) {
285 this.locale = locale; 287 this.locale = locale;
286 } else if (!locale) { 288 } else if (!locale) {
287 this.locale = this._getDefaultLocale(); 289 this.locale = this._getDefaultLocale();
288 } 290 }
291
292 debug(`Set locale to "${this.locale}"`);
289 } 293 }
290 294
291 _getDefaultLocale() { 295 _getDefaultLocale() {