From 7300db703c7b8c9a98ac5e25c74a27e78bd90487 Mon Sep 17 00:00:00 2001 From: Addison Beck Date: Thu, 20 Jan 2022 10:30:01 -0500 Subject: [PATCH] [Bug] Change method scope for internal StateMigrationService methods (#619) A couple of helper methods were recently added to the StateMigrationService, but they were set to private and can't be used in children. Some clients, like the Directory Connector, extend the StateMigrationService and need access to these methods. --- common/src/services/stateMigration.service.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/common/src/services/stateMigration.service.ts b/common/src/services/stateMigration.service.ts index 511c8dc477..ab19af05c0 100644 --- a/common/src/services/stateMigration.service.ts +++ b/common/src/services/stateMigration.service.ts @@ -409,26 +409,26 @@ export class StateMigrationService { } } - private get options(): StorageOptions { + protected get options(): StorageOptions { return { htmlStorageLocation: HtmlStorageLocation.Local }; } - private get(key: string): Promise { + protected get(key: string): Promise { return this.storageService.get(key, this.options); } - private set(key: string, value: any): Promise { + protected set(key: string, value: any): Promise { if (value == null) { return this.storageService.remove(key, this.options); } return this.storageService.save(key, value, this.options); } - private async getGlobals(): Promise { + protected async getGlobals(): Promise { return await this.get(keys.global); } - private async getCurrentStateVersion(): Promise { + protected async getCurrentStateVersion(): Promise { return (await this.getGlobals())?.stateVersion; } }