We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0e93f66 commit 3d11da6Copy full SHA for 3d11da6
packages/plugins/driver-memory/src/memory-driver.ts
@@ -1086,9 +1086,10 @@ export class InMemoryDriver implements IDataDriver {
1086
* false positives in Node.js runtimes that partially polyfill globals.
1087
*/
1088
private isBrowserEnvironment(): boolean {
1089
- return typeof globalThis.window !== 'undefined'
1090
- && typeof globalThis.document !== 'undefined'
1091
- && typeof globalThis.localStorage?.setItem === 'function';
+ const g = globalThis as any;
+ return typeof g.window !== 'undefined'
+ && typeof g.document !== 'undefined'
1092
+ && typeof g.localStorage?.setItem === 'function';
1093
}
1094
1095
/**
0 commit comments