We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f531b28 commit 7eceaa3Copy full SHA for 7eceaa3
src/client/common/process/rawProcessApis.ts
@@ -102,6 +102,7 @@ export function plainExec(
102
dispose: () => {
103
if (!proc.killed) {
104
proc.kill();
105
+ deferred.reject(new Error('Process was killed'));
106
}
107
},
108
};
src/client/common/utils/async.ts
@@ -50,11 +50,17 @@ class DeferredImpl<T> implements Deferred<T> {
50
51
52
public resolve(_value: T | PromiseLike<T>) {
53
+ if (this.completed) {
54
+ return;
55
+ }
56
this._resolve.apply(this.scope ? this.scope : this, [_value]);
57
this._resolved = true;
58
59
60
public reject(_reason?: string | Error | Record<string, unknown>) {
61
62
63
64
this._reject.apply(this.scope ? this.scope : this, [_reason]);
65
this._rejected = true;
66
0 commit comments