aboutsummaryrefslogtreecommitdiff
path: root/node_modules/debug/src/node.js
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/debug/src/node.js')
-rw-r--r--node_modules/debug/src/node.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/node_modules/debug/src/node.js b/node_modules/debug/src/node.js
index 4fa564b0d..af6129768 100644
--- a/node_modules/debug/src/node.js
+++ b/node_modules/debug/src/node.js
@@ -38,7 +38,7 @@ exports.inspectOpts = Object.keys(process.env).filter(function (key) {
var prop = key
.substring(6)
.toLowerCase()
- .replace(/_([a-z])/, function (_, k) { return k.toUpperCase() });
+ .replace(/_([a-z])/g, function (_, k) { return k.toUpperCase() });
// coerce string value into JS value
var val = process.env[key];
@@ -231,7 +231,12 @@ function createWritableStdioStream (fd) {
*/
function init (debug) {
- debug.inspectOpts = util._extend({}, exports.inspectOpts);
+ debug.inspectOpts = {};
+
+ var keys = Object.keys(exports.inspectOpts);
+ for (var i = 0; i < keys.length; i++) {
+ debug.inspectOpts[keys[i]] = exports.inspectOpts[keys[i]];
+ }
}
/**