Commit 1d78bcde8d9f2130394a1832348d805fe9b77467
Don't log requests by default
It interferes with npm client outputcel committed on 9/2/2018, 9:16:06 PM
Parent: 6882576c265ff0d371d67f78d09a7711254f2b27
Files changed
index.js | changed |
index.js | ||
---|---|---|
@@ -524,9 +524,11 @@ | ||
524 | 524 … | || remoteAddr === '127.0.0.1' |
525 | 525 … | } |
526 | 526 … | |
527 | 527 … | Req.prototype.serve = function () { |
528 | - console.log(this.req.method, this.req.url, formatHost(this.req.socket.remoteAddress)) | |
528 … | + if (process.env.DEBUG) { | |
529 … | + console.log(this.req.method, this.req.url, formatHost(this.req.socket.remoteAddress)) | |
530 … | + } | |
529 | 531 … | this.res.setTimeout(0) |
530 | 532 … | var pathname = this.req.url.replace(/\?.*/, '') |
531 | 533 … | var m |
532 | 534 … | if ((m = /^\/(\^|%5[Ee])?(%25.*sha256)+(\/.*)$/.exec(pathname))) { |
Built with git-ssb-web