Fix errors
This commit is contained in:
+8
-8
@@ -26,7 +26,7 @@ export class ExponentialBackoffStoppedRetriesError extends Error {
|
|||||||
*/
|
*/
|
||||||
export class ExponentialBackoffNumberTooSmallError extends Error {
|
export class ExponentialBackoffNumberTooSmallError extends Error {
|
||||||
constructor(option: string, value: number, min: number) {
|
constructor(option: string, value: number, min: number) {
|
||||||
super(`Exponential backoff option "${option}" is too small. Must be at least ${min}`);
|
super(`Exponential backoff option "${option}" is too small. Must be at least ${min}. Received value: ${value}`);
|
||||||
this.name = 'ExponentialBackoffNumberTooSmallError';
|
this.name = 'ExponentialBackoffNumberTooSmallError';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -36,7 +36,7 @@ export class ExponentialBackoffNumberTooSmallError extends Error {
|
|||||||
*/
|
*/
|
||||||
export class ExponentialBackoffNumberOutOfBoundsError extends Error {
|
export class ExponentialBackoffNumberOutOfBoundsError extends Error {
|
||||||
constructor(option: string, value: number, min: number, max: number) {
|
constructor(option: string, value: number, min: number, max: number) {
|
||||||
super(`Exponential backoff option "${option}" is out of bounds. Must be between ${min} and ${max}`);
|
super(`Exponential backoff option "${option}" is out of bounds. Must be between ${min} and ${max}. Received value: ${value}`);
|
||||||
this.name = 'ExponentialBackoffNumberOutOfBoundsError';
|
this.name = 'ExponentialBackoffNumberOutOfBoundsError';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -44,10 +44,10 @@ export class ExponentialBackoffNumberOutOfBoundsError extends Error {
|
|||||||
/**
|
/**
|
||||||
* Error thrown when an exponential backoff option is an invalid infinite integer
|
* Error thrown when an exponential backoff option is an invalid infinite integer
|
||||||
*/
|
*/
|
||||||
export class ExponentialBackoffInvalidInfiniteIntegerError extends Error {
|
export class ExponentialBackoffNumberNotFiniteError extends Error {
|
||||||
constructor(option: string) {
|
constructor(option: string, value: number) {
|
||||||
super(`Exponential backoff option "${option}" is invalid. Must be a finite number`);
|
super(`Exponential backoff option "${option}" is invalid. Must be a finite number. Received value: ${value}`);
|
||||||
this.name = 'ExponentialBackoffInvalidInfiniteIntegerError';
|
this.name = 'ExponentialBackoffNumberNotFiniteError';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -55,8 +55,8 @@ export class ExponentialBackoffInvalidInfiniteIntegerError extends Error {
|
|||||||
* Error thrown when an exponential backoff option is not an integer
|
* Error thrown when an exponential backoff option is not an integer
|
||||||
*/
|
*/
|
||||||
export class ExponentialBackoffNonIntegerError extends Error {
|
export class ExponentialBackoffNonIntegerError extends Error {
|
||||||
constructor(option: string) {
|
constructor(option: string, value: number) {
|
||||||
super(`Exponential backoff option "${option}" is invalid. Must be an integer`);
|
super(`Exponential backoff option "${option}" is invalid. Must be an integer. Received value: ${value}`);
|
||||||
this.name = 'ExponentialBackoffNonIntegerError';
|
this.name = 'ExponentialBackoffNonIntegerError';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user