repositories
/
e-mobility-charging-stations-simulator.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2d4e5e7
)
refactor: cleanup null test
author
Jérôme Benoit
<jerome.benoit@sap.com>
Sat, 16 Dec 2023 16:58:21 +0000
(17:58 +0100)
committer
Jérôme Benoit
<jerome.benoit@sap.com>
Sat, 16 Dec 2023 16:58:21 +0000
(17:58 +0100)
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
src/worker/WorkerSet.ts
patch
|
blob
|
blame
|
history
diff --git
a/src/worker/WorkerSet.ts
b/src/worker/WorkerSet.ts
index 17b5b6dde201c85f4c0af0cbaf3574d33968fb03..047d03ad0ee09aa9922e4b66667f34ddc7f5b8e6 100644
(file)
--- a/
src/worker/WorkerSet.ts
+++ b/
src/worker/WorkerSet.ts
@@
-30,10
+30,7
@@
export class WorkerSet extends WorkerAbstract<WorkerData> {
*/
constructor(workerScript: string, workerOptions: WorkerOptions) {
super(workerScript, workerOptions);
- if (
- this.workerOptions.elementsPerWorker === null ||
- this.workerOptions.elementsPerWorker === undefined
- ) {
+ if (this.workerOptions.elementsPerWorker == null) {
throw new TypeError('Elements per worker is not defined');
}
if (!Number.isSafeInteger(this.workerOptions.elementsPerWorker)) {