@rpldy/shared
Advanced tools
Comparing version 0.13.1 to 0.13.2
@@ -12,4 +12,2 @@ "use strict"; | ||
var _utils = require("./utils"); | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
@@ -19,14 +17,8 @@ | ||
const isEnvDebug = () => { | ||
var _process, _process$env; | ||
return !(0, _utils.isProduction)() && ((_process = process) === null || _process === void 0 ? void 0 : (_process$env = _process.env) === null || _process$env === void 0 ? void 0 : _process$env.DEBUG); | ||
}; | ||
const isDebugOn = () => { | ||
if (typeof isDebug !== "boolean") { | ||
isDebug = isEnvDebug() || (0, _hasWindow.default)() && ("location" in window && !!~window.location.search.indexOf("rpldy_debug=true") || window[_consts.DEBUG_LOG_KEY] === true); | ||
isDebug = (0, _hasWindow.default)() && ("location" in window && !!~window.location.search.indexOf("rpldy_debug=true") || window[_consts.DEBUG_LOG_KEY] === true); | ||
} | ||
return isDebug; | ||
return !!isDebug; | ||
}; | ||
@@ -33,0 +25,0 @@ |
import { DEBUG_LOG_KEY } from "./consts"; | ||
import hasWindow from "./utils/hasWindow"; | ||
import { isProduction } from "./utils"; | ||
let isDebug; | ||
const isEnvDebug = () => { | ||
var _process, _process$env; | ||
return !isProduction() && ((_process = process) === null || _process === void 0 ? void 0 : (_process$env = _process.env) === null || _process$env === void 0 ? void 0 : _process$env.DEBUG); | ||
}; | ||
const isDebugOn = () => { | ||
if (typeof isDebug !== "boolean") { | ||
isDebug = isEnvDebug() || hasWindow() && ("location" in window && !!~window.location.search.indexOf("rpldy_debug=true") || window[DEBUG_LOG_KEY] === true); | ||
isDebug = hasWindow() && ("location" in window && !!~window.location.search.indexOf("rpldy_debug=true") || window[DEBUG_LOG_KEY] === true); | ||
} | ||
return isDebug; | ||
return !!isDebug; | ||
}; | ||
@@ -19,0 +12,0 @@ |
{ | ||
"version": "0.13.1", | ||
"version": "0.13.2", | ||
"name": "@rpldy/shared", | ||
@@ -30,3 +30,3 @@ "description": "internal set of utils+types for react-uploady", | ||
}, | ||
"gitHead": "b9f6aac92b75d4561f9614c411bec10123684ec3" | ||
"gitHead": "b6e8a4fe04b33e613a76805947582743c114b79d" | ||
} |
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
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
36669
946