X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Fworker%2FWorkerUtils.ts;h=f36c6046d626d5d4850f1b75dca253edae043b15;hb=75e6075c1ae340bca0ba41e9a836ae066ef9b6db;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) ) }