From 96483cf4452c876f66ff71553209e8eaddba38fd Mon Sep 17 00:00:00 2001 From: Harvmaster Date: Sat, 18 Jul 2026 16:26:07 +0000 Subject: [PATCH] Documentation and spelling --- source/exponential-backoff.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/source/exponential-backoff.ts b/source/exponential-backoff.ts index 32b4355..b13274f 100644 --- a/source/exponential-backoff.ts +++ b/source/exponential-backoff.ts @@ -57,6 +57,7 @@ export class ExponentialBackoff { * @param options - The configuration for the exponential backoff * * @throws An {@link ExponentialBackoffMaxRetriesHitError} with all the errors that were thrown by the task function + * @throws An {@link ExponentialBackoffStoppedRetriesError} if the abort signal is activated * * @returns The result of the function */ @@ -163,6 +164,7 @@ export class ExponentialBackoff { * @param onError - The callback to call when an error occurs * * @throws An {@link ExponentialBackoffMaxRetriesHitError} with all the errors that were thrown by the task function + * @throws An {@link ExponentialBackoffStoppedRetriesError} if the abort signal is activated * * @returns The result of the function */ @@ -194,7 +196,7 @@ export class ExponentialBackoff { const errorInstance = error instanceof Error ? error : new Error(`${error}`); onError(errorInstance); - // If we have unlimited attemps, don't append this to the errors array to prevent a memory leak. + // If we have unlimited attempts, don't append this to the errors array to prevent a memory leak. if (!unlimitedAttempts) { errors.push(errorInstance); }