X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Fworker%2FWorkerUtils.ts;h=f36c6046d626d5d4850f1b75dca253edae043b15;hb=b1396a2e5ab5f52238df71daeb9da0ef6b12807a;hp=5cd19f12cea02b1f101c9be10dac19895abc2bdb;hpb=68220b423c52da387fdf41967dd8c738da0ff52e;p=e-mobility-charging-stations-simulator.git diff --git a/src/worker/WorkerUtils.ts b/src/worker/WorkerUtils.ts index 5cd19f12..f36c6046 100644 --- a/src/worker/WorkerUtils.ts +++ b/src/worker/WorkerUtils.ts @@ -3,7 +3,7 @@ import { getRandomValues } from 'node:crypto' import chalk from 'chalk' export const sleep = async (milliSeconds: number): Promise => { - return await new Promise((resolve) => + return await new Promise(resolve => setTimeout(resolve as () => void, milliSeconds) ) }