Skip to content

Commit

Permalink
util: named anonymous functions
Browse files Browse the repository at this point in the history
PR-URL: #20408
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Matheus Marchini <matheus@sthima.com>
  • Loading branch information
ccoxwell authored and MylesBorins committed May 8, 2018
1 parent 391c420 commit 1b9c40c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -277,12 +277,12 @@ function debuglog(set) {
if (!debugs[set]) {
if (debugEnvRegex.test(set)) {
const pid = process.pid;
debugs[set] = function() {
debugs[set] = function debug() {
const msg = exports.format.apply(exports, arguments);
console.error('%s %d: %s', set, pid, msg);
};
} else {
debugs[set] = function() {};
debugs[set] = function debug() {};
}
}
return debugs[set];
Expand Down

0 comments on commit 1b9c40c

Please sign in to comment.