Merge pull request #15966 from Snuffleupagus/GlobalWorkerOptions-defaults
Simplify setting the `GlobalWorkerOptions` default values (PR 9480 follow-up)
This commit is contained in:
commit
16aef95937
@ -27,14 +27,7 @@
|
|||||||
/** @type {GlobalWorkerOptionsType} */
|
/** @type {GlobalWorkerOptionsType} */
|
||||||
const GlobalWorkerOptions = Object.create(null);
|
const GlobalWorkerOptions = Object.create(null);
|
||||||
|
|
||||||
GlobalWorkerOptions.workerPort =
|
GlobalWorkerOptions.workerPort = null;
|
||||||
GlobalWorkerOptions.workerPort === undefined
|
GlobalWorkerOptions.workerSrc = "";
|
||||||
? null
|
|
||||||
: GlobalWorkerOptions.workerPort;
|
|
||||||
|
|
||||||
GlobalWorkerOptions.workerSrc =
|
|
||||||
GlobalWorkerOptions.workerSrc === undefined
|
|
||||||
? ""
|
|
||||||
: GlobalWorkerOptions.workerSrc;
|
|
||||||
|
|
||||||
export { GlobalWorkerOptions };
|
export { GlobalWorkerOptions };
|
||||||
|
Loading…
x
Reference in New Issue
Block a user