Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
return JSON.parse(JSON.stringify(object)) as T;
}
- static isIterable(obj): boolean {
+ static isIterable<T>(obj: T): boolean {
if (obj) {
return typeof obj[Symbol.iterator] === 'function';
}
private getWorkerSetElementByWorker(worker: Worker): WorkerSetElement {
let workerSetElt: WorkerSetElement;
this.workerSet.forEach((workerSetElement) => {
- if (JSON.stringify(workerSetElement.worker) === JSON.stringify(worker)) {
+ if (workerSetElement.worker.threadId === worker.threadId) {
workerSetElt = workerSetElement;
}
});