@nger/fk-upload 1.0.167 → 1.0.168

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.
@@ -38,7 +38,8 @@ class UploadTask extends rabbitmq_1.Task {
38
38
  return next && next();
39
39
  }
40
40
  if (!(0, fs_1.existsSync)(task.path)) {
41
- throw new Error(`file ${task.path} not found`);
41
+ fail();
42
+ return next && next();
42
43
  }
43
44
  // > 1G give up
44
45
  if (task.total >= 1024 * 1024 * 1024) {
@@ -49,7 +50,8 @@ class UploadTask extends rabbitmq_1.Task {
49
50
  const localSize = fk.getLocalSize(old.path);
50
51
  if (cloudSize != localSize) {
51
52
  // not my task
52
- throw new Error(`not mine task`);
53
+ fail();
54
+ return next && next();
53
55
  // await db.manager.update(FkDownloadTaskEntity, task.filename, { status: 0 })
54
56
  // const download = await taskService.createDownLoadTask(old.url, old.loginId, old.topicId);
55
57
  // await manager.send(download);
@@ -76,7 +78,8 @@ class UploadTask extends rabbitmq_1.Task {
76
78
  this.errorCount = 0;
77
79
  }
78
80
  this.errorCount += 1;
79
- throw e;
81
+ fail();
82
+ return next && next();
80
83
  });
81
84
  }
82
85
  else {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nger/fk-upload",
3
- "version": "1.0.167",
3
+ "version": "1.0.168",
4
4
  "description": "nger fk upload",
5
5
  "main": "dist/electon.js",
6
6
  "types": "dist/core.d.ts",