diff --git a/packages/beacon-node/src/chain/chain.ts b/packages/beacon-node/src/chain/chain.ts index 08eeb17c28c9..6f0dc7307d59 100644 --- a/packages/beacon-node/src/chain/chain.ts +++ b/packages/beacon-node/src/chain/chain.ts @@ -963,7 +963,8 @@ export class BeaconChain implements IBeaconChain { // Set pivotValidatorIndex to 0 if `historicalValidatorLengths` does not // contain validator length for cpEpoch to ensure `newFinalizedValidators` to be empty - const pivotValidatorIndex = headState.epochCtx.historicalValidatorLengths.get((headEpoch - cpEpoch + 1) * -1) ?? 0; + const pivotValidatorIndex = + headState.epochCtx.historicalValidatorLengths.get((headEpoch - cpEpoch + 1) * -1) ?? 0; // Note EIP-6914 will break this logic const newFinalizedValidators = headState.epochCtx.unfinalizedPubkey2index.filter( diff --git a/packages/beacon-node/test/sim/6110-interop.test.ts b/packages/beacon-node/test/sim/6110-interop.test.ts index 58850ad7e1f0..52da74756d30 100644 --- a/packages/beacon-node/test/sim/6110-interop.test.ts +++ b/packages/beacon-node/test/sim/6110-interop.test.ts @@ -415,7 +415,7 @@ describe("executionEngine / ExecutionEngineHttp", function () { // Its historicalValidatorLengths should store lengths for epoch 3 and 4 hence size should be 2 console.log(`haha ${epochCtx.historicalValidatorLengths.size}`); if (epochCtx.historicalValidatorLengths.size !== 2) { - throw Error("Historical validator lengths is not updated correctly") + throw Error("Historical validator lengths is not updated correctly"); } if (headState.depositReceiptsStartIndex === UNSET_DEPOSIT_RECEIPTS_START_INDEX) {