@travetto/worker
Advanced tools
Comparing version 1.1.0-alpha.3 to 1.1.0-alpha.4
@@ -12,3 +12,3 @@ { | ||
"dependencies": { | ||
"@travetto/base": "^1.1.0-alpha.3", | ||
"@travetto/base": "^1.1.0-alpha.4", | ||
"@types/generic-pool": "^3.1.9", | ||
@@ -35,4 +35,4 @@ "generic-pool": "^3.7.1" | ||
}, | ||
"version": "1.1.0-alpha.3", | ||
"gitHead": "44e5f014530873f13e0fb5c6e300978152eae02a" | ||
"version": "1.1.0-alpha.4", | ||
"gitHead": "ecffdabc4d620f09dd4154fc59f1058165aeef86" | ||
} |
@@ -14,3 +14,3 @@ import { InputSource } from './types'; | ||
private src: Itr<X>; | ||
private ondeck: X; | ||
private ondeck?: X; | ||
private done = false; | ||
@@ -57,3 +57,3 @@ | ||
const out = this.ondeck; | ||
const out = this.ondeck!; | ||
delete this.ondeck; | ||
@@ -60,0 +60,0 @@ return out; |
import { Util, ShutdownManager } from '@travetto/base'; | ||
import { Timeout } from './timeout'; | ||
function canCancel(o: any): o is { cancel(): any } { | ||
return o && 'cancel' in o; | ||
} | ||
/** | ||
@@ -51,4 +55,3 @@ * Build an execution barrier to handle various limitations | ||
const el = this.barriers.get(k); | ||
if (el && 'cancel' in el) { | ||
// @ts-ignore | ||
if (canCancel(el)) { | ||
el.cancel(); | ||
@@ -55,0 +58,0 @@ } |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
24231
557