Browse Source

complete flow

Tim 4 years ago
parent
commit
a4b19447ef
2 changed files with 4 additions and 0 deletions
  1. 2
    0
      dist/index.js
  2. 2
    0
      src/index.ts

+ 2
- 0
dist/index.js View File

54
                     stop();
54
                     stop();
55
                     break;
55
                     break;
56
                 case Events.FAILED:
56
                 case Events.FAILED:
57
+                    reject(new Error('FAILED'));
57
                 case Events.CLOSED:
58
                 case Events.CLOSED:
59
+                    reject(new Error('CLOSED'));
58
                     stop();
60
                     stop();
59
                     break;
61
                     break;
60
                 case Events.ERROR:
62
                 case Events.ERROR:

+ 2
- 0
src/index.ts View File

95
                     stop();
95
                     stop();
96
                     break;
96
                     break;
97
                 case Events.FAILED:
97
                 case Events.FAILED:
98
+                    reject(new Error('FAILED'));
98
                 case Events.CLOSED:
99
                 case Events.CLOSED:
100
+                    reject(new Error('CLOSED'));
99
                     stop();
101
                     stop();
100
                     break;
102
                     break;
101
                 case Events.ERROR:
103
                 case Events.ERROR: