make JSDoc work on Node.js <5.10.0 (#1393)

This commit is contained in:
Jeff Williams 2017-07-10 11:07:26 -07:00
parent f6af93b108
commit 510e890ae8
2 changed files with 2 additions and 2 deletions

View File

@ -132,7 +132,7 @@
"callback-return": "off",
"global-require": "off", // TODO: enable
"handle-callback-err": "error",
"no-buffer-constructor": "error",
"no-buffer-constructor": "off", // TODO: enable when we stop supporting Node.js 4.x
"no-mixed-requires": "error",
"no-new-require": "error",
"no-path-concat": "error",

View File

@ -100,7 +100,7 @@ exports.copyFileSync = function(inFile, outDir, fileName) {
var read;
var write;
var buffer = Buffer.alloc(BUF_LENGTH);
var buffer = new Buffer(BUF_LENGTH);
var bytesRead = 1;
var outFile = path.join( outDir, fileName || path.basename(inFile) );
var pos = 0;