fix: ensure inflight requests id cannot be duplicated
[e-mobility-charging-stations-simulator.git] / src / utils / ConfigurationUtils.ts
index 925e7c131c47b471761e7f2369040271bdcc3283..2a85bb0e2fd5686b603bf9a405181c3bc13f1b64 100644 (file)
@@ -3,10 +3,10 @@ import { fileURLToPath } from 'node:url'
 
 import chalk from 'chalk'
 
-import { Constants } from './Constants.js'
-import { isNotEmptyString, logPrefix as utilsLogPrefix } from './Utils.js'
 import { type ElementsPerWorkerType, type FileType, StorageType } from '../types/index.js'
 import { WorkerProcessType } from '../worker/index.js'
+import { Constants } from './Constants.js'
+import { isNotEmptyString, logPrefix as utilsLogPrefix } from './Utils.js'
 
 export const logPrefix = (): string => {
   return utilsLogPrefix(' Simulator configuration |')
@@ -71,7 +71,7 @@ export const checkWorkerElementsPerWorker = (
   elementsPerWorker: ElementsPerWorkerType | undefined
 ): void => {
   if (
-    elementsPerWorker !== undefined &&
+    elementsPerWorker != null &&
     elementsPerWorker !== 'auto' &&
     elementsPerWorker !== 'all' &&
     !Number.isSafeInteger(elementsPerWorker)