diff --git a/packages/web/src/common/clients/storage-client/web-storage-client.ts b/packages/web/src/common/clients/storage-client/web-storage-client.ts index 188a74d33..61f5a0e00 100644 --- a/packages/web/src/common/clients/storage-client/web-storage-client.ts +++ b/packages/web/src/common/clients/storage-client/web-storage-client.ts @@ -7,9 +7,9 @@ export class WebStorageClient implements StorageClient { this.storageType = storageType; } - get storage() { - if (!window) { - return; + get storage(): Storage | null { + if (typeof window === "undefined") { + return null; } if (this.storageType === "LOCAL") { return window.localStorage;