Skip to content

Commit

Permalink
Remove old hack for some old Node 0.6 versions (#567)
Browse files Browse the repository at this point in the history
Co-authored-by: Ron Korving <[email protected]>
  • Loading branch information
ronkorving and Ron Korving authored Jun 27, 2020
1 parent 4ae3824 commit 554837b
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions bin/bunyan
Original file line number Diff line number Diff line change
Expand Up @@ -1701,16 +1701,5 @@ function main(argv) {
}

if (require.main === module) {
// HACK guard for <https://github.com/trentm/json/issues/24>.
// We override the `process.stdout.end` guard that core node.js puts in
// place. The real fix is that `.end()` shouldn't be called on stdout
// in node core. Node v0.6.9 fixes that. Only guard for v0.6.0..v0.6.8.
if ([0, 6, 0] <= nodeVer && nodeVer <= [0, 6, 8]) {
var stdout = process.stdout;
stdout.end = stdout.destroy = stdout.destroySoon = function () {
/* pass */
};
}

main(process.argv);
}

0 comments on commit 554837b

Please sign in to comment.