hadron-ipc
Advanced tools
Comparing version 2.4.0 to 2.5.0
22
index.js
@@ -5,6 +5,20 @@ 'use strict'; | ||
if (isRenderer) { | ||
module.exports = require('./lib/renderer'); | ||
} else { | ||
module.exports = require('./lib/main'); | ||
let isElectron = false; | ||
try { | ||
isElectron = typeof require('electron') !== 'string'; | ||
} catch (err) { /* not electron */ } | ||
function requireExportModule() { | ||
if (!isElectron) { | ||
if (process.env.NODE_ENV !== 'test') { | ||
// eslint-disable-next-line no-console | ||
console.warn('Unsupported environment for hadron-ipc'); | ||
} | ||
return {}; | ||
} | ||
return isRenderer ? require('./lib/renderer') : require('./lib/main'); | ||
} | ||
module.exports = requireExportModule(); |
{ | ||
"name": "hadron-ipc", | ||
"description": "Simplified IPC for electron apps.", | ||
"version": "2.4.0", | ||
"version": "2.5.0", | ||
"scripts": { | ||
@@ -38,3 +38,3 @@ "check": "npm run lint && npm run depcheck", | ||
}, | ||
"gitHead": "e00da432655fbd1b723fd693527bf481f4c1e645" | ||
"gitHead": "455c6523f99a08c6796480d59727b53bdfa441f0" | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
39820
9
112
1