From 79995a28ebb58257d71040d02ebd3cfa4d136c22 Mon Sep 17 00:00:00 2001 From: addison Date: Fri, 12 Nov 2021 12:35:50 -0500 Subject: [PATCH] [refactor] Remove unecassary argements from electron crypto state calls --- electron/src/services/electronCrypto.service.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/electron/src/services/electronCrypto.service.ts b/electron/src/services/electronCrypto.service.ts index 23b0b438..9602d5dc 100644 --- a/electron/src/services/electronCrypto.service.ts +++ b/electron/src/services/electronCrypto.service.ts @@ -6,7 +6,6 @@ import { StateService } from 'jslib-common/abstractions/state.service'; import { CryptoService } from 'jslib-common/services/crypto.service'; import { KeySuffixOptions } from 'jslib-common/enums/keySuffixOptions'; -import { StorageLocation } from 'jslib-common/enums/storageLocation'; export class ElectronCryptoService extends CryptoService { @@ -31,7 +30,7 @@ export class ElectronCryptoService extends CryptoService { */ private async upgradeSecurelyStoredKey() { // attempt key upgrade, but if we fail just delete it. Keys will be stored property upon unlock anyway. - const key = await this.stateService.getCryptoMasterKey({ storageLocation: StorageLocation.Disk, useSecureStorage: true }); + const key = await this.stateService.getCryptoMasterKey(); if (key == null) { return; @@ -49,6 +48,6 @@ export class ElectronCryptoService extends CryptoService { this.logService.error(e); } - await this.stateService.setCryptoMasterKey(null, { storageLocation: StorageLocation.Disk, useSecureStorage: true }); + await this.stateService.setCryptoMasterKey(null); } }