xjs-common 9.1.0-alpha.3 → 9.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/func/u-file.js
CHANGED
|
@@ -127,7 +127,7 @@ var UFile;
|
|
|
127
127
|
throw new xjs_err_1.XjsErr(s_errCode, "The destination directory is not found.");
|
|
128
128
|
let cmd = "unzip", options = null, availableCmd = true;
|
|
129
129
|
if (destDir)
|
|
130
|
-
options = `-d
|
|
130
|
+
options = `-d ${destDir}`;
|
|
131
131
|
const check = () => { try {
|
|
132
132
|
(0, child_process_1.execSync)(`${cmd} --help`, { stdio: "ignore" });
|
|
133
133
|
}
|
|
@@ -216,9 +216,7 @@ class HttpResolverContext {
|
|
|
216
216
|
const stream = fs.createWriteStream(dest);
|
|
217
217
|
res.pipe(stream);
|
|
218
218
|
stream.on("finish", () => stream.close());
|
|
219
|
-
|
|
220
|
-
stream.on("error", reject);
|
|
221
|
-
return;
|
|
219
|
+
resolve({ headers: res.headers });
|
|
222
220
|
}
|
|
223
221
|
catch (e) {
|
|
224
222
|
if (e instanceof xjs_err_1.XjsErr)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "xjs-common",
|
|
3
|
-
"version": "9.1.0
|
|
3
|
+
"version": "9.1.0",
|
|
4
4
|
"description": "library modules for nodejs + typescript that bundled general-purpose implementations.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -28,4 +28,4 @@
|
|
|
28
28
|
"ts-node": "^10.9.1",
|
|
29
29
|
"typescript": "^4.9.5"
|
|
30
30
|
}
|
|
31
|
-
}
|
|
31
|
+
}
|