mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-07-21 02:29:23 +00:00
feature(util) retExec -> exec.ret
This commit is contained in:
parent
58a3a6ff3e
commit
7332c7b325
15 changed files with 38 additions and 38 deletions
|
|
@ -24,7 +24,7 @@
|
|||
function create(params) {
|
||||
var gzip, read, write, isFsWrite,
|
||||
p = params,
|
||||
func = Util.retExec(p.callback),
|
||||
func = Util.exec.ret(p.callback),
|
||||
options = {
|
||||
bufferSize: 4 * 1024
|
||||
};
|
||||
|
|
@ -84,7 +84,7 @@
|
|||
});
|
||||
|
||||
readStream.on('error', function(error) {
|
||||
Util.retExec(callback, error);
|
||||
Util.exec.ret(callback, error);
|
||||
});
|
||||
|
||||
readStream.on('end', function() {
|
||||
|
|
|
|||
|
|
@ -431,7 +431,7 @@
|
|||
names = [];
|
||||
}
|
||||
|
||||
process = Util.retExec(callbackProcess, from);
|
||||
process = Util.exec.ret(callbackProcess, from);
|
||||
|
||||
if (isLast)
|
||||
Util.exec(callback, null);
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
exports.onDelete = onDelete;
|
||||
|
||||
function onDelete(name, files, query, callback) {
|
||||
var func = Util.retExec(callback),
|
||||
var func = Util.exec.ret(callback),
|
||||
fileNames = Util.slice(files),
|
||||
rmFile = fs.unlink,
|
||||
rmDir = fse.delete;
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
|
||||
function onGet(query, name, callback) {
|
||||
var error, hash,
|
||||
func = Util.retExec(callback);
|
||||
func = Util.exec.ret(callback);
|
||||
|
||||
switch (query) {
|
||||
case 'size':
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@
|
|||
exports.onPut = onPut;
|
||||
|
||||
function onPut(name, query, readStream, callback) {
|
||||
var func = Util.retExec(callback),
|
||||
var func = Util.exec.ret(callback),
|
||||
baseName = path.basename(name);
|
||||
|
||||
switch(query) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue