1
0
mirror of https://github.com/bitwarden/jslib synced 2025-12-17 08:43:18 +00:00

Convert Sets to Arrays before saving locally (#383)

This commit is contained in:
Thomas Rittson
2021-05-19 10:10:20 +10:00
committed by GitHub
parent 3d4ecaeb6a
commit c8eca37183

View File

@@ -39,6 +39,9 @@ export class ElectronStorageService implements StorageService {
} }
save(key: string, obj: any): Promise<any> { save(key: string, obj: any): Promise<any> {
if (obj instanceof Set) {
obj = Array.from(obj);
}
this.store.set(key, obj); this.store.set(key, obj);
return Promise.resolve(); return Promise.resolve();
} }