Skip to content

Commit f2faa8c

Browse files
fix: do not fail if no process (#1440)
1 parent b950877 commit f2faa8c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/util/minimal.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,9 @@ util.emptyObject = Object.freeze ? Object.freeze({}) : /* istanbul ignore next *
5252
* @type {boolean}
5353
* @const
5454
*/
55-
util.isNode = Boolean(process && process.versions && process.versions.node);
55+
util.isNode = Boolean(typeof process !== "undefined" && process &&
56+
typeof process.versions !== "undefined" && process.versions &&
57+
process.versions.node);
5658

5759
/**
5860
* Tests if the specified value is an integer.

0 commit comments

Comments
 (0)