[Home](./index.md) > [bitburner](./bitburner.md) > [Gang](./bitburner.gang.md) > [nextUpdate](./bitburner.gang.nextupdate.md) ## Gang.nextUpdate() method Sleeps until the next Gang update has happened. **Signature:** ```typescript nextUpdate(): Promise; ``` **Returns:** Promise<number> Promise that resolves to the number of milliseconds of Gang time that were processed in the previous update (2000 - 5000 ms). ## Remarks RAM cost: 1 GB The amount of real time spent asleep between updates can vary due to "bonus time". ## Example ```js while (true) { const duration = await ns.gang.nextUpdate(); ns.print(`Gang completed ${ns.tFormat(duration)} of activity.`); ns.print(`Bonus time remaining: ${ns.tFormat(ns.gang.getBonusTime())}`); // Manage the Gang } ```