From 8be5b4f063a94082d6baa1f8b095fd17a9640d7e Mon Sep 17 00:00:00 2001 From: acolytec3 <17355484+acolytec3@users.noreply.github.com> Date: Tue, 3 Oct 2023 09:58:13 -0400 Subject: [PATCH] nits --- packages/client/src/rpc/modules/engine.ts | 2 +- packages/client/src/service/fullethereumservice.ts | 4 ++-- packages/client/src/service/skeleton.ts | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/client/src/rpc/modules/engine.ts b/packages/client/src/rpc/modules/engine.ts index 43299a7901..62fcf6ef59 100644 --- a/packages/client/src/rpc/modules/engine.ts +++ b/packages/client/src/rpc/modules/engine.ts @@ -666,7 +666,7 @@ export class Engine { this.chain, this.chainCache ) - if (headBlock === undefined || error) { + if (headBlock === undefined || error !== undefined) { let response = error if (!response) { const validationError = `Error assembling block during init` diff --git a/packages/client/src/service/fullethereumservice.ts b/packages/client/src/service/fullethereumservice.ts index d5669aca2f..cbe5541ab6 100644 --- a/packages/client/src/service/fullethereumservice.ts +++ b/packages/client/src/service/fullethereumservice.ts @@ -174,8 +174,8 @@ export class FullEthereumService extends Service { if (txs[0].length > 0) this.txPool.sendNewTxHashes(txs, [peer]) }) - // skeleton needs to be opened before syncronizers are opened - // but after chain is opened, which skeleton's open will take care of + // skeleton needs to be opened before synchronizers are opened + // but after chain is opened, which skeleton.open() does internally await this.skeleton?.open() await super.open() await this.execution.open() diff --git a/packages/client/src/service/skeleton.ts b/packages/client/src/service/skeleton.ts index e7308dbac0..81fb19c342 100644 --- a/packages/client/src/service/skeleton.ts +++ b/packages/client/src/service/skeleton.ts @@ -323,7 +323,7 @@ export class Skeleton extends MetaDBManager { async setHead(head: Block, force = true, init = false, reorgthrow = false): Promise { return this.runWithLock(async () => { if (this.started === 0) { - throw Error(`skeleton setHead called before its opened`) + throw Error(`skeleton setHead called before being opened`) } this.config.logger.debug(