diff --git a/src/mixins/lang.js b/src/mixins/lang.js index 39be8ba6e..e395a449f 100644 --- a/src/mixins/lang.js +++ b/src/mixins/lang.js @@ -45,8 +45,7 @@ export default { */ async changeLang(lang, options = {}) { const persist = options.persist !== false; - let message = (await langModules["../lang/" + lang + ".json"]()) - .default; + let message = (await langModules["../lang/" + lang + ".json"]()).default; this.$i18n.setLocaleMessage(lang, message); this.$i18n.locale = lang; if (persist) { diff --git a/src/pages/StatusPage.vue b/src/pages/StatusPage.vue index f2ce4b81f..96510e54e 100644 --- a/src/pages/StatusPage.vue +++ b/src/pages/StatusPage.vue @@ -208,13 +208,14 @@
- - @@ -956,29 +957,30 @@ export default { this.slug = "default"; } - this.getData().then((res) => { - this.config = res.data.config; + this.getData() + .then((res) => { + this.config = res.data.config; - if (!this.config.domainNameList) { - this.config.domainNameList = []; - } + if (!this.config.domainNameList) { + this.config.domainNameList = []; + } - if (!("language" in this.config)) { - this.config.language = null; - } + if (!("language" in this.config)) { + this.config.language = null; + } - if (this.config.icon) { - this.imgDataUrl = this.config.icon; - } + if (this.config.icon) { + this.imgDataUrl = this.config.icon; + } - // Apply configured language if the visitor hasn't set their own preference - if (this.config.language && !localStorage.locale) { - this.$root.setLanguage(this.config.language, { persist: false }); - } + // Apply configured language if the visitor hasn't set their own preference + if (this.config.language && !localStorage.locale) { + this.$root.setLanguage(this.config.language, { persist: false }); + } - this.incident = res.data.incident; - this.maintenanceList = res.data.maintenanceList; - this.$root.publicGroupList = res.data.publicGroupList; + this.incident = res.data.incident; + this.maintenanceList = res.data.maintenanceList; + this.$root.publicGroupList = res.data.publicGroupList; if (!this.config.domainNameList) { this.config.domainNameList = [];