From e155daf4496a18ab0a7f2237fcd5e81b9c41c7ed Mon Sep 17 00:00:00 2001 From: InventiveCoder Date: Tue, 10 Dec 2024 14:31:24 +0800 Subject: [PATCH] chore: fix some typos in comment Signed-off-by: InventiveCoder --- packages/node/src/network/discv5/worker.ts | 2 +- packages/node/src/network/gossip/topic.ts | 4 ++-- packages/node/src/network/processor/gossipValidatorFn.ts | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/node/src/network/discv5/worker.ts b/packages/node/src/network/discv5/worker.ts index d70b1fb6..0abfb5be 100644 --- a/packages/node/src/network/discv5/worker.ts +++ b/packages/node/src/network/discv5/worker.ts @@ -33,7 +33,7 @@ function enrRelevance(enr: ENR): ENRRelevance { // A consumer _should_ call `close` before terminating the worker to cleanly exit discv5 before destroying the thread // A `setEnrValue` function is also provided to update the host ENR key-values shared in the discv5 network. -// Cloned data from instatiation +// Cloned data from instantiation const workerData = worker.workerData as Discv5WorkerData; // eslint-disable-next-line @typescript-eslint/strict-boolean-expressions if (!workerData) throw Error("workerData must be defined"); diff --git a/packages/node/src/network/gossip/topic.ts b/packages/node/src/network/gossip/topic.ts index 86d40cdd..932a126d 100644 --- a/packages/node/src/network/gossip/topic.ts +++ b/packages/node/src/network/gossip/topic.ts @@ -41,7 +41,7 @@ export class GossipTopicCache implements IGossipTopicCache { } /** - * Stringify a GossipTopic into a spec-ed formated topic string + * Stringify a GossipTopic into a spec-ed formatted topic string */ export function stringifyGossipTopic(topic: GossipTopic): string { const topicType = stringifyGossipTopicType(topic); @@ -50,7 +50,7 @@ export function stringifyGossipTopic(topic: GossipTopic): string { } /** - * Stringify a GossipTopic into a spec-ed formated partial topic string + * Stringify a GossipTopic into a spec-ed formatted partial topic string */ function stringifyGossipTopicType(topic: GossipTopic): string { switch (topic.type) { diff --git a/packages/node/src/network/processor/gossipValidatorFn.ts b/packages/node/src/network/processor/gossipValidatorFn.ts index 56126bd1..6519f601 100644 --- a/packages/node/src/network/processor/gossipValidatorFn.ts +++ b/packages/node/src/network/processor/gossipValidatorFn.ts @@ -19,7 +19,7 @@ export type ValidatorFnModules = {}; * - The message.data should already by uncompressed when computing its msgID * * All logging and metrics associated with gossip object validation should happen in this function. We want to know - * - In debug logs what objects are we processing, the result and some succint metadata + * - In debug logs what objects are we processing, the result and some succinct metadata * - In metrics what's the throughput and ratio of accept/ignore/reject per type * * @see getGossipHandlers for reasoning on why GossipHandlerFn are used for gossip validation.