Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

use stream pipi instead of deprecated pump method

  • Loading branch information...
commit b6ca8574aae41355038b7351ad5b24d9e70d67a1 1 parent 78bdd5b
@Shogun147 authored
Showing with 4 additions and 3 deletions.
  1. +4 −3 lib/utils.js
View
7 lib/utils.js
@@ -306,9 +306,10 @@ module.exports = {
var src = Fs.createReadStream(source);
var dest = Fs.createWriteStream(destination);
- pump(src, dest, function(error) {
- callback(error);
- });
+ src.pipe(dest);
+
+ src.on('error', callback);
+ src.on('end', callback);
});
}
Please sign in to comment.
Something went wrong with that request. Please try again.