Disable Worker termination on dev

This helps inspect the source code without it disappearing right from under your nose in 10 seconds.
This commit is contained in:
Ingvar Stepanyan
2021-01-18 19:41:41 +00:00
parent 30528c2330
commit 02d038a8f3

View File

@@ -58,9 +58,11 @@ for (const methodName of methodNames) {
signal.removeEventListener('abort', onAbort);
// Start a timer to clear up the worker.
this._workerTimeout = setTimeout(() => {
this._terminateWorker();
}, workerTimeout);
if (__PRODUCTION__) {
this._workerTimeout = setTimeout(() => {
this._terminateWorker();
}, workerTimeout);
}
});
});