mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-07-26 17:29:27 +00:00
feature(rest) add unzip
This commit is contained in:
parent
83aa10660c
commit
41654e09d3
12 changed files with 66 additions and 4 deletions
|
|
@ -52,8 +52,12 @@
|
|||
Util.exec(p.callback, error);
|
||||
};
|
||||
|
||||
if (p.gzip) {
|
||||
gzip = zlib.createGzip();
|
||||
if (p.gzip || p.gunzip) {
|
||||
if (p.gzip)
|
||||
gzip = zlib.createGzip();
|
||||
else
|
||||
gzip = zlib.createGunzip();
|
||||
|
||||
read.on('error', onError);
|
||||
read = read.pipe(gzip);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue