mirror of
https://github.com/bitwarden/web
synced 2025-12-10 21:33:16 +00:00
Fix various bugs in Options page (#1418)
* Remove duplicate message in toast * Set starting variables properly
This commit is contained in:
@@ -74,8 +74,12 @@ export class OptionsComponent implements OnInit {
|
|||||||
this.disableIcons = await this.stateService.getDisableFavicon();
|
this.disableIcons = await this.stateService.getDisableFavicon();
|
||||||
this.enableGravatars = await this.stateService.getEnableGravitars();
|
this.enableGravatars = await this.stateService.getEnableGravitars();
|
||||||
this.enableFullWidth = await this.stateService.getEnableFullWidth();
|
this.enableFullWidth = await this.stateService.getEnableFullWidth();
|
||||||
this.locale = (await this.stateService.getLocale()) ?? this.startingLocale;
|
|
||||||
this.theme = (await this.stateService.getTheme()) ?? this.startingTheme;
|
this.locale = await this.stateService.getLocale();
|
||||||
|
this.startingLocale = this.locale;
|
||||||
|
|
||||||
|
this.theme = await this.stateService.getTheme();
|
||||||
|
this.startingTheme = this.theme;
|
||||||
}
|
}
|
||||||
|
|
||||||
async submit() {
|
async submit() {
|
||||||
@@ -104,10 +108,7 @@ export class OptionsComponent implements OnInit {
|
|||||||
if (this.locale !== this.startingLocale) {
|
if (this.locale !== this.startingLocale) {
|
||||||
window.location.reload();
|
window.location.reload();
|
||||||
} else {
|
} else {
|
||||||
this.platformUtilsService.showToast("success", null, [
|
this.platformUtilsService.showToast("success", null, this.i18nService.t("optionsUpdated"));
|
||||||
this.i18nService.t("optionsUpdated"),
|
|
||||||
this.i18nService.t("optionsUpdated"),
|
|
||||||
]);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user