瀏覽代碼

Merge pull request #15 from Pranomvignesh/check-worker

fix(workerManager.js) : Added a check for the existence of the worker
Alexandru Dima 3 年之前
父節點
當前提交
a53ac54f4e
共有 1 個文件被更改,包括 3 次插入1 次删除
  1. 3 1
      src/workerManager.ts

+ 3 - 1
src/workerManager.ts

@@ -80,7 +80,9 @@ export class WorkerManager {
 				_client = client;
 			})
 			.then((_) => {
-				return this._worker.withSyncedResources(resources);
+				if (this._worker) {
+					return this._worker.withSyncedResources(resources);
+				}
 			})
 			.then((_) => _client);
 	}