feature(pipe) pipe.create -> pipe

This commit is contained in:
coderaiser 2014-10-31 11:32:13 -04:00
parent d4dfdba158
commit 9b9e50efd1
7 changed files with 15 additions and 14 deletions

View file

@ -62,7 +62,7 @@
} else {
name = names.shift();
pipe.create(name, write, options, function(error) {
pipe(name, write, options, function(error) {
if (error)
callback(error);
else

View file

@ -101,7 +101,7 @@
stopOnError: true
}, callback);
else
pipe.create(from, to, callback);
pipe(from, to, callback);
});
};
})();

View file

@ -22,7 +22,7 @@
};
if (!is || !fstream || !tar)
pipe.create(from, to, options, callback);
pipe(from, to, options, callback);
else
createTar(from, function(readStream) {
var dir, name,
@ -34,7 +34,7 @@
to = dir + path.sep + name + '.tar.gz';
}
pipe.create(readStream, to, options, callback);
pipe(readStream, to, options, callback);
});
});
};
@ -55,7 +55,7 @@
write = to;
}
pipe.create(from, write, options, callback);
pipe(from, write, options, callback);
};
function createTar(from, callback) {

View file

@ -1,13 +1,14 @@
(function () {
'use strict';
var Util = require('../util'),
type = Util.type,
fs = require('fs'),
zlib = require('zlib');
var fs = require('fs'),
zlib = require('zlib'),
Util = require('../util'),
type = Util.type;
exports.create = create;
exports.getBody = getBody;
module.exports = create;
module.exports.getBody = getBody;
/**
* create pipe

View file

@ -227,7 +227,7 @@
range : range
};
pipe.create(p.name, p.response, options, function(error) {
pipe(p.name, p.response, options, function(error) {
if (error)
sendError(error, params);
});

View file

@ -45,7 +45,7 @@
error = 'hash: not suported, try update node';
callback(Error(error));
} else
pipe.create(name, hashStream, function (error) {
pipe(name, hashStream, function (error) {
var hex;
if (!error)

View file

@ -30,7 +30,7 @@
switch(query) {
default:
pipe.create(readStream, name, onSave);
pipe(readStream, name, onSave);
break;
case 'dir':