Skip to content
This repository was archived by the owner on Jul 9, 2021. It is now read-only.

Commit edaa3ef

Browse files
committed
[fixed] the isNode check for when the process variable exists in the browser
1 parent fbbdd35 commit edaa3ef

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/util.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
* // or - var isNode = require('webcompiler').isNode;
2020
* // or - var isNode = require('webcompiler/lib/util').isNode;
2121
*/
22-
export const isNode = 'undefined' !== typeof process && 'node' === process.release.name;
22+
export const isNode = 'undefined' !== typeof process && process.release && 'node' === process.release.name;
2323

2424
/**
2525
* `true` if the `NODE_ENV` environment variable is set to `"production"`

0 commit comments

Comments
 (0)