Skip to content

Commit

Permalink
Use math.round
Browse files Browse the repository at this point in the history
  • Loading branch information
nflaig committed Oct 11, 2024
1 parent d441e3a commit 8bb3298
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/beacon-node/src/api/impl/validator/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -631,7 +631,7 @@ export function getValidatorApi(
: Promise.reject(new Error("Engine disabled"));

const [builder, engine] = await resolveOrRacePromises([builderPromise, enginePromise], {
resolveTimeoutMs: Math.max(0, BLOCK_PRODUCTION_RACE_CUTOFF_MS - chain.clock.secFromSlot(slot) * 1000),
resolveTimeoutMs: Math.max(0, BLOCK_PRODUCTION_RACE_CUTOFF_MS - Math.round(chain.clock.secFromSlot(slot) * 1000)),
raceTimeoutMs: BLOCK_PRODUCTION_RACE_TIMEOUT_MS,
signal: controller.signal,
});
Expand Down

0 comments on commit 8bb3298

Please sign in to comment.