From 1b0ab38ada682f779e9c5e19ad4d3416f8eee375 Mon Sep 17 00:00:00 2001 From: Addison Beck Date: Fri, 8 Jul 2022 16:54:15 -0400 Subject: [PATCH] [fix] Generator settings not persisting across web sessions (#3074) --- libs/common/src/services/state.service.ts | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/libs/common/src/services/state.service.ts b/libs/common/src/services/state.service.ts index c2ae787482..fcb4a78595 100644 --- a/libs/common/src/services/state.service.ts +++ b/libs/common/src/services/state.service.ts @@ -1940,52 +1940,52 @@ export class StateService< async getPasswordGenerationOptions(options?: StorageOptions): Promise { return ( - await this.getAccount(this.reconcileOptions(options, await this.defaultOnDiskOptions())) + await this.getAccount(this.reconcileOptions(options, await this.defaultOnDiskLocalOptions())) )?.settings?.passwordGenerationOptions; } async setPasswordGenerationOptions(value: any, options?: StorageOptions): Promise { const account = await this.getAccount( - this.reconcileOptions(options, await this.defaultOnDiskOptions()) + this.reconcileOptions(options, await this.defaultOnDiskLocalOptions()) ); account.settings.passwordGenerationOptions = value; await this.saveAccount( account, - this.reconcileOptions(options, await this.defaultOnDiskOptions()) + this.reconcileOptions(options, await this.defaultOnDiskLocalOptions()) ); } async getUsernameGenerationOptions(options?: StorageOptions): Promise { return ( - await this.getAccount(this.reconcileOptions(options, await this.defaultOnDiskOptions())) + await this.getAccount(this.reconcileOptions(options, await this.defaultOnDiskLocalOptions())) )?.settings?.usernameGenerationOptions; } async setUsernameGenerationOptions(value: any, options?: StorageOptions): Promise { const account = await this.getAccount( - this.reconcileOptions(options, await this.defaultOnDiskOptions()) + this.reconcileOptions(options, await this.defaultOnDiskLocalOptions()) ); account.settings.usernameGenerationOptions = value; await this.saveAccount( account, - this.reconcileOptions(options, await this.defaultOnDiskOptions()) + this.reconcileOptions(options, await this.defaultOnDiskLocalOptions()) ); } async getGeneratorOptions(options?: StorageOptions): Promise { return ( - await this.getAccount(this.reconcileOptions(options, await this.defaultOnDiskOptions())) + await this.getAccount(this.reconcileOptions(options, await this.defaultOnDiskLocalOptions())) )?.settings?.generatorOptions; } async setGeneratorOptions(value: any, options?: StorageOptions): Promise { const account = await this.getAccount( - this.reconcileOptions(options, await this.defaultOnDiskOptions()) + this.reconcileOptions(options, await this.defaultOnDiskLocalOptions()) ); account.settings.generatorOptions = value; await this.saveAccount( account, - this.reconcileOptions(options, await this.defaultOnDiskOptions()) + this.reconcileOptions(options, await this.defaultOnDiskLocalOptions()) ); }