xjs-common 9.0.0 → 9.0.2

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.
@@ -218,8 +218,12 @@ class HttpResolverContext {
218
218
  resolve({ headers: res.headers });
219
219
  }
220
220
  catch (e) {
221
- this.error(e);
222
- reject(new xjs_err_1.XjsErr(s_errCode, "Failed to download a file."));
221
+ if (e instanceof xjs_err_1.XjsErr)
222
+ reject(e);
223
+ else {
224
+ this.error(e);
225
+ reject(new xjs_err_1.XjsErr(s_errCode, "Failed to download a file."));
226
+ }
223
227
  }
224
228
  }
225
229
  const bfs = [];
@@ -260,7 +264,7 @@ class HttpResolverContext {
260
264
  const pathArray = opPath.split("/");
261
265
  pathArray.pop();
262
266
  if (!u_file_1.UFile.exists(pathArray))
263
- throw new xjs_err_1.XjsErr(s_errCode, "Directory of the download path was not found.");
267
+ throw new xjs_err_1.XjsErr(s_errCode, "Directory of the download file was not found.");
264
268
  return opPath;
265
269
  }
266
270
  if (st.isDirectory()) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xjs-common",
3
- "version": "9.0.0",
3
+ "version": "9.0.2",
4
4
  "description": "library modules for nodejs + typescript that bundled general-purpose implementations.",
5
5
  "repository": {
6
6
  "type": "git",