From 28e7640ecda4aee05c6620fc62a668a3df9f34c4 Mon Sep 17 00:00:00 2001 From: Ryan Goulding Date: Wed, 7 Feb 2024 14:40:08 -0800 Subject: [PATCH] chore: devtools; fix JSDoc names, spelling, typing, etc. The nittiest patch ever. Signed-off-by: Ryan Goulding --- packages/devtools/src/common/assertion.ts | 2 +- packages/devtools/src/common/bytes.ts | 2 +- packages/devtools/src/common/promise.ts | 4 +++- packages/devtools/src/transactions/signer.ts | 2 +- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/packages/devtools/src/common/assertion.ts b/packages/devtools/src/common/assertion.ts index 9708b1b7a..17a0243b1 100644 --- a/packages/devtools/src/common/assertion.ts +++ b/packages/devtools/src/common/assertion.ts @@ -8,7 +8,7 @@ import { deepStrictEqual } from 'assert' * const theyDontMatch = isDeepEqual({ a: 1 }, { a: '1' }) // false * ``` * - * @param {T} a + * @param {unknown} a * @param {unknown} b * @returns {boolean} */ diff --git a/packages/devtools/src/common/bytes.ts b/packages/devtools/src/common/bytes.ts index 76fedc3c8..998afcb3a 100644 --- a/packages/devtools/src/common/bytes.ts +++ b/packages/devtools/src/common/bytes.ts @@ -39,7 +39,7 @@ export const isZero = (value: PossiblyBytes | PossiblyBigInt | null | undefined) /** * Turns a potentially zero address into undefined * - * @param {PossiblyBytes | PossiblyBigInt | null | undefined} address + * @param {PossiblyBytes | PossiblyBigInt | null | undefined} value * * @returns {string | undefined} */ diff --git a/packages/devtools/src/common/promise.ts b/packages/devtools/src/common/promise.ts index 845c0c4de..ca4ddb8cd 100644 --- a/packages/devtools/src/common/promise.ts +++ b/packages/devtools/src/common/promise.ts @@ -143,7 +143,9 @@ type RetryStrategy = Factory< * @returns {(task: Factory) => Factory} */ export const createRetryFactory = - (strategy: RetryStrategy = createSimpleRetryStrategy(3)) => + ( + strategy: RetryStrategy = createSimpleRetryStrategy(3) + ): ((task: Factory) => Factory) => (task: Factory): Factory => async (...input) => { // We'll store the last used input in this variable diff --git a/packages/devtools/src/transactions/signer.ts b/packages/devtools/src/transactions/signer.ts index da19dd120..eb9d6be42 100644 --- a/packages/devtools/src/transactions/signer.ts +++ b/packages/devtools/src/transactions/signer.ts @@ -38,7 +38,7 @@ export const createSignAndSend = const successful: OmniTransactionWithReceipt[] = [] for (const [index, transaction] of transactions.entries()) { - // We want to refer to this transaction by index so we create an ordinal for it (1st, 2nd etc) + // We want to refer to this transaction by index, so we create an ordinal for it (1st, 2nd etc.) const ordinal = pluralizeOrdinal(index + 1) try {