MCPcopy
hub / github.com/Unitech/pm2 / useIfDefined

Function useIfDefined

modules/pm2-io-agent/constants.js:37–43  ·  view source on GitHub ↗
(value, fallback)

Source from the content-addressed store, hash-verified

35 * @return {Boolean}
36 */
37const useIfDefined = (value, fallback) => {
38 if (typeof value === 'undefined') {
39 return fallback
40 } else {
41 return value === 'true'
42 }
43}
44
45let cst = {
46 DEBUG: process.env.PM2_DEBUG || false,

Callers 1

constants.jsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…