Clean up NODE_DEBUG detection

It wasn't detecting if NODE_DEBUG=0
This commit is contained in:
Ryan Dahl committed 2010-03-23 20:56:51 -07:00
1 parent 8e9ec4abea
commit 218d7e9f2d
1 file changed
+1 -3
+1 -3
View File
@@ -323,9 +323,7 @@ global.clearInterval = global.clearTimeout;
// Modules
var debugLevel = 0;
if ("NODE_DEBUG" in process.env) debugLevel = 1;
var debugLevel = parseInt(process.env["NODE_DEBUG"]);
function debug (x) {
if (debugLevel > 0) {
process.binding('stdio').writeError(x + "\n");