Skip to content

Commit

Permalink
Adding globalThis typeof check (#6127)
Browse files Browse the repository at this point in the history
  • Loading branch information
marklundin authored Mar 8, 2024
1 parent 3876ceb commit b9fc6e0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/core/platform.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ const platform = {
*
* @type {object}
*/
global: globalThis ??
global: (typeof globalThis !== 'undefined' && globalThis) ??
(environment === 'browser' && window) ??
(environment === 'node' && global) ??
(environment === 'worker' && self),
Expand Down

0 comments on commit b9fc6e0

Please sign in to comment.