Merge pull request #140 from niieani/patch-1

Use 'node' version when using Electron with nodeIntegration enabled
master
Linus Unnebäck 8 years ago committed by GitHub
commit c676a64fb2

@ -30,7 +30,7 @@ function isInBrowser() {
return true;
if (environment === "node")
return false;
return ((typeof window !== 'undefined') && (typeof XMLHttpRequest === 'function'));
return ((typeof window !== 'undefined') && (typeof XMLHttpRequest === 'function') && !(window.require && window.module && window.process && window.process.type === "renderer"));
}
function hasGlobalProcessEventEmitter() {

Loading…
Cancel
Save