fix(dom) unpack -> extract

This commit is contained in:
coderaiser 2015-07-09 10:36:41 -04:00
parent 27ca342407
commit fd2dbbdaa3
2 changed files with 3 additions and 21 deletions

View file

@ -506,7 +506,7 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog;
fileFrom = {
from : dirPath,
to : dirPath,
to : dirPath + name,
names : names
};
break;
@ -536,7 +536,7 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog;
* unzip file
*
*/
this.unpack = function() {
this.extract = function() {
twopack('extract');
};

View file

@ -273,26 +273,8 @@
}
function pack(from, to, names, fn) {
var name;
from = root(from);
if (to)
to = root(to);
else
to = from;
if (names.length > 1) {
name = path.basename(to);
} else {
name = names[0];
}
to = path.join(to, name);
if (!/\.tar\.gz$/.test(to)) {
to += '.tar.gz';
}
to = root(to);
if (!names) {
names = [